Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

object-keys

Package Overview
Dependencies
Maintainers
1
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

object-keys - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

38

.jscs.json
{
"additionalRules": [],
"requireSemicolons": true,
"disallowMultipleSpaces": true,
"disallowIdentifierNames": [],
"requireCurlyBraces": ["if", "else", "for", "while", "do", "try", "catch"],

@@ -66,4 +72,34 @@

"mark": "'"
}
},
"disallowOperatorBeforeLineBreak": [],
"requireSpaceBeforeKeywords": [
"do",
"for",
"if",
"else",
"switch",
"case",
"try",
"catch",
"finally",
"while",
"with",
"return"
],
"validateAlignedFunctionParameters": {
"lineBreakAfterOpeningBraces": true,
"lineBreakBeforeClosingBraces": true
},
"requirePaddingNewLinesBeforeExport": true,
"validateNewlineAfterArrayElements": {
"maximum": 7
},
"requirePaddingNewLinesAfterUseStrict": true
}

@@ -0,1 +1,7 @@

1.0.4 / 2015-05-23
=================
* Fix a Safari 5.0 bug with `Object.keys` not working with `arguments`
* Test on latest `node` and `io.js`
* Update `jscs`, `tape`, `eslint`, `nsp`, `is`, `editorconfig-tools`, `covert`
1.0.3 / 2015-01-06

@@ -2,0 +8,0 @@ =================

@@ -6,2 +6,3 @@ 'use strict';

var toStr = Object.prototype.toString;
var slice = Array.prototype.slice;
var isArgs = require('./isArguments');

@@ -66,2 +67,17 @@ var hasDontEnumBug = !({ 'toString': null }).propertyIsEnumerable('toString');

Object.keys = keysShim;
} else {
var keysWorksWithArguments = (function () {
// Safari 5.0 bug
return (Object.keys(arguments) || '').length === 2;
}(1, 2));
if (!keysWorksWithArguments) {
var originalKeys = Object.keys;
Object.keys = function keys(object) {
if (isArgs(object)) {
return originalKeys(slice.call(object));
} else {
return originalKeys(object);
}
};
}
}

@@ -68,0 +84,0 @@ return Object.keys || keysShim;

12

isArguments.js

@@ -9,10 +9,10 @@ 'use strict';

if (!isArgs) {
isArgs = str !== '[object Array]'
&& value !== null
&& typeof value === 'object'
&& typeof value.length === 'number'
&& value.length >= 0
&& toStr.call(value.callee) === '[object Function]';
isArgs = str !== '[object Array]' &&
value !== null &&
typeof value === 'object' &&
typeof value.length === 'number' &&
value.length >= 0 &&
toStr.call(value.callee) === '[object Function]';
}
return isArgs;
};
{
"name": "object-keys",
"version": "1.0.3",
"version": "1.0.4",
"author": "Jordan Harband",

@@ -30,11 +30,11 @@ "description": "An Object.keys replacement, in case Object.keys is not available. From https://github.com/es-shims/es5-shim",

"devDependencies": {
"foreach": "~2.0.5",
"is": "~2.2.0",
"tape": "~3.0.3",
"indexof": "~0.0.1",
"covert": "1.0.0",
"jscs": "~1.9.0",
"editorconfig-tools": "~0.0.1",
"nsp": "~0.5.2",
"eslint": "~0.11.0"
"foreach": "^2.0.5",
"is": "^3.0.1",
"tape": "^4.0.0",
"indexof": "^0.0.1",
"covert": "^1.1.0",
"jscs": "^1.13.1",
"editorconfig-tools": "^0.1.1",
"nsp": "^1.0.1",
"eslint": "^0.21.0"
},

@@ -41,0 +41,0 @@ "testling": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc