mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-10 02:47:50 +00:00
Bump to v4.14.0.
This commit is contained in:
@@ -1,7 +1,8 @@
|
||||
var stubArray = require('./stubArray');
|
||||
var overArg = require('./_overArg'),
|
||||
stubArray = require('./stubArray');
|
||||
|
||||
/** Built-in value references. */
|
||||
var getOwnPropertySymbols = Object.getOwnPropertySymbols;
|
||||
/* Built-in method references for those with the same name as other `lodash` methods. */
|
||||
var nativeGetSymbols = Object.getOwnPropertySymbols;
|
||||
|
||||
/**
|
||||
* Creates an array of the own enumerable symbol properties of `object`.
|
||||
@@ -10,15 +11,6 @@ var getOwnPropertySymbols = Object.getOwnPropertySymbols;
|
||||
* @param {Object} object The object to query.
|
||||
* @returns {Array} Returns the array of symbols.
|
||||
*/
|
||||
function getSymbols(object) {
|
||||
// Coerce `object` to an object to avoid non-object errors in V8.
|
||||
// See https://bugs.chromium.org/p/v8/issues/detail?id=3443 for more details.
|
||||
return getOwnPropertySymbols(Object(object));
|
||||
}
|
||||
|
||||
// Fallback for IE < 11.
|
||||
if (!getOwnPropertySymbols) {
|
||||
getSymbols = stubArray;
|
||||
}
|
||||
var getSymbols = nativeGetSymbols ? overArg(nativeGetSymbols, Object) : stubArray;
|
||||
|
||||
module.exports = getSymbols;
|
||||
|
||||
Reference in New Issue
Block a user