mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-10-06 00:52:58 +00:00
FIXED: replace js Array.map function with capp API
Also fixed BlockExpression description to match a little more with cocoa impl.
This commit is contained in:
1 parent
e72a42fd2d
commit
117ac0f5d6
1 file changed
+4
-6
@@ -65,12 +65,10 @@
|
||||
{
|
||||
var args = [];
|
||||
|
||||
if (_arguments !== nil)
|
||||
[_arguments enumerateObjectsUsingBlock:function(exp, idx)
|
||||
{
|
||||
args = _arguments.map(function(expression){
|
||||
return [expression expressionValueWithObject:object context:context];
|
||||
});
|
||||
}
|
||||
[args addObject:[exp expressionValueWithObject:object context:context]];
|
||||
}];
|
||||
|
||||
return _block(object, args, context);
|
||||
}
|
||||
@@ -89,7 +87,7 @@
|
||||
|
||||
- (CPString)description
|
||||
{
|
||||
return [CPString stringWithFormat:@"Block(0x%@)", [CPString stringWithHash:[self UID]]];
|
||||
return [CPString stringWithFormat:@"Block(function, %@)", [_arguments description]];
|
||||
}
|
||||
|
||||
@end
|
||||
Reference in new issue
Block a user