mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-01 15:57:48 +00:00
Cleanup nonEnumProps assignment.
This commit is contained in:
15
lodash.js
15
lodash.js
@@ -712,17 +712,14 @@
|
||||
nonEnumProps[errorClass] = nonEnumProps[funcClass] = nonEnumProps[regexpClass] = { 'constructor': true, 'toString': true };
|
||||
nonEnumProps[objectClass] = { 'constructor': true };
|
||||
|
||||
(function() {
|
||||
var length = shadowedProps.length;
|
||||
while (length--) {
|
||||
var key = shadowedProps[length];
|
||||
for (var className in nonEnumProps) {
|
||||
if (hasOwnProperty.call(nonEnumProps, className) && !hasOwnProperty.call(nonEnumProps[className], key)) {
|
||||
nonEnumProps[className][key] = false;
|
||||
}
|
||||
arrayEach(shadowedProps, function(key) {
|
||||
for (var className in nonEnumProps) {
|
||||
if (hasOwnProperty.call(nonEnumProps, className)) {
|
||||
var props = nonEnumProps[className];
|
||||
props[key] = hasOwnProperty.call(props, key);
|
||||
}
|
||||
}
|
||||
}());
|
||||
});
|
||||
|
||||
/*--------------------------------------------------------------------------*/
|
||||
|
||||
|
||||
Reference in New Issue
Block a user