minor changes
This commit is contained in:
parent
73a74ea9c6
commit
d2322388dc
1 changed files with 3 additions and 5 deletions
|
@ -140,8 +140,8 @@ Ox.polyfill.isArray = function(value) {
|
|||
Ox.polyfill.JSON <o> see https://github.com/douglascrockford/JSON-js
|
||||
> Ox.polyfill.JSON.parse('{"a": [1, 2], "b": [3, 4]}')
|
||||
{a: [1, 2], b: [3, 4]}
|
||||
> Ox.polyfill.JSON.stringify([(function(){ return arguments; }()), false, null, 0, Infinity, NaN, / /, void 0])
|
||||
'[{},false,null,0,null,null,{},null]'
|
||||
> Ox.polyfill.JSON.stringify([(function(){ return arguments; }()), false, null, 0, -0, Infinity, NaN, / /, void 0])
|
||||
'[{},false,null,0,0,null,null,{},null]'
|
||||
> Ox.polyfill.JSON.stringify(new Date()).length
|
||||
24
|
||||
@*/
|
||||
|
@ -208,9 +208,7 @@ Ox.polyfill.keys = function(object) {
|
|||
}
|
||||
var key, ret = [];
|
||||
for (key in object) {
|
||||
if (Object.prototype.hasOwnProperty.call(object, key)) {
|
||||
ret.push(key);
|
||||
}
|
||||
Object.prototype.hasOwnProperty.call(object, key) && ret.push(key);
|
||||
}
|
||||
return ret;
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue