diff --git a/Foundation/CPArray+KVO.j b/Foundation/CPArray+KVO.j index 64ccd2a8f..f9685ce47 100644 --- a/Foundation/CPArray+KVO.j +++ b/Foundation/CPArray+KVO.j @@ -447,7 +447,7 @@ kvoOperators["sum"] = function sumOperator(self, _cmd, param) -(void)addObserver:(id)observer forKeyPath:(CPString)aKeyPath options:(unsigned)options context:(id)context { - if ([isa instanceMethodForSelector:_cmd]==[NSArray instanceMethodForSelector:_cmd]) + if ([isa instanceMethodForSelector:_cmd] === [CPArray instanceMethodForSelector:_cmd]) [CPException raise:CPInvalidArgumentException reason:"Unsupported method on CPArray"]; else [super addObserver:observer forKeyPath:aKeyPath options:options context:context]; @@ -455,7 +455,7 @@ kvoOperators["sum"] = function sumOperator(self, _cmd, param) -(void)removeObserver:(id)observer forKeyPath:(CPString)aKeyPath { - if ([isa instanceMethodForSelector:_cmd]==[NSArray instanceMethodForSelector:_cmd]) + if ([isa instanceMethodForSelector:_cmd] === [CPArray instanceMethodForSelector:_cmd]) [CPException raise:CPInvalidArgumentException reason:"Unsupported method on CPArray"]; else [super removeObserver:observer forKeyPath:aKeyPath];