Files
lodash/.internal/baseProperty.js
John-David Dalton 6cb3460fce Remove semicolons.
2017-02-05 22:22:04 -08:00

13 lines
329 B
JavaScript

/**
* The base implementation of `property` without support for deep paths.
*
* @private
* @param {string} key The key of the property to get.
* @returns {Function} Returns the new accessor function.
*/
function baseProperty(key) {
return object => object == null ? undefined : object[key]
}
export default baseProperty