mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-09 10:27:49 +00:00
Bump to v3.7.0.
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
var isLength = require('../internal/isLength'),
|
||||
var getLength = require('../internal/getLength'),
|
||||
isLength = require('../internal/isLength'),
|
||||
keys = require('../object/keys');
|
||||
|
||||
/**
|
||||
@@ -22,7 +23,7 @@ var isLength = require('../internal/isLength'),
|
||||
* // => 7
|
||||
*/
|
||||
function size(collection) {
|
||||
var length = collection ? collection.length : 0;
|
||||
var length = collection ? getLength(collection) : 0;
|
||||
return isLength(length) ? length : keys(collection).length;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user