mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-26 10:11:03 +00:00
([-removeObserver:]): Do not raise an exception
when removing nil observer, jusr return. This is WO4.5 and MacOSX behaviour. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@18971 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
ba6c91e5f1
commit
ced2196a57
1 changed files with 2 additions and 3 deletions
|
@ -899,8 +899,7 @@ static NSNotificationCenter *default_center = nil;
|
|||
- (void) removeObserver: (id)observer
|
||||
{
|
||||
if (observer == nil)
|
||||
[NSException raise: NSInvalidArgumentException
|
||||
format: @"Nil observer passed to removeObserver:"];
|
||||
return;
|
||||
|
||||
[self removeObserver: observer name: nil object: nil];
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue