mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-06 17:47:49 +00:00
Ensure _.result calls deep function with correct context.
This commit is contained in:
committed by
jdalton
parent
c594bda77f
commit
11ab3034b1
@@ -12497,6 +12497,14 @@
|
||||
var actual = _.result(object, 'd', object.c);
|
||||
strictEqual(actual, 1);
|
||||
});
|
||||
|
||||
test('should call deep property method with correct context', 1, function() {
|
||||
var value = {
|
||||
'deep': object
|
||||
};
|
||||
|
||||
strictEqual(_.result(value, ['deep', 'c']), 1);
|
||||
})
|
||||
}());
|
||||
|
||||
/*--------------------------------------------------------------------------*/
|
||||
|
||||
Reference in New Issue
Block a user