mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-10 02:47:50 +00:00
Bump to v4.11.2.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
var baseProperty = require('./_baseProperty'),
|
||||
basePropertyDeep = require('./_basePropertyDeep'),
|
||||
isKey = require('./_isKey');
|
||||
isKey = require('./_isKey'),
|
||||
toKey = require('./_toKey');
|
||||
|
||||
/**
|
||||
* Creates a function that returns the value at `path` of a given object.
|
||||
@@ -25,7 +26,7 @@ var baseProperty = require('./_baseProperty'),
|
||||
* // => [1, 2]
|
||||
*/
|
||||
function property(path) {
|
||||
return isKey(path) ? baseProperty(path) : basePropertyDeep(path);
|
||||
return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);
|
||||
}
|
||||
|
||||
module.exports = property;
|
||||
|
||||
Reference in New Issue
Block a user