mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-09 02:17:50 +00:00
Ensure the lodash underscore version of _.result matches v1.4.4 behavior.
Former-commit-id: c4c1946e49f12ddc4ba2f0f65a9ef7c9727d79ca
This commit is contained in:
8
build.js
8
build.js
@@ -1753,6 +1753,14 @@
|
||||
' }'
|
||||
].join('\n'));
|
||||
|
||||
// replace `_.result`
|
||||
source = replaceFunction(source, 'result', [
|
||||
' function result(object, property) {',
|
||||
' var value = object ? object[property] : null;',
|
||||
' return isFunction(value) ? object[property]() : value;',
|
||||
' }'
|
||||
].join('\n'));
|
||||
|
||||
// replace `_.template`
|
||||
source = replaceFunction(source, 'template', [
|
||||
' function template(text, data, options) {',
|
||||
|
||||
Reference in New Issue
Block a user