1
0
Fork 0
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
353 B

//if (typeof String.addLeadingChar)
if (typeof Object.size !== "function") {
var fnSize = function (obj) { return Object.keys(obj).length; };
if (typeof Object.keys !== "function") {
fnSize = function(obj) {
var size = 0, key;
for (key in obj) {
if (obj.hasOwnProperty(key)) size++;
}
return size;
};
}
Object.size = fnSize;
}