From 35b9ca1332e392d67ba530fbb45e5f62de12666a Mon Sep 17 00:00:00 2001 From: Matthew Phillips Date: Wed, 18 Jan 2017 13:01:46 -0500 Subject: [PATCH] Upgrade to steal-npm 1.0.6 --- ext/npm-utils.js | 6 +++++- package.json | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/ext/npm-utils.js b/ext/npm-utils.js index dc8074704..c1b263ed4 100644 --- a/ext/npm-utils.js +++ b/ext/npm-utils.js @@ -47,7 +47,7 @@ var utils = { if(deep) { if(utils.isArray(val)) { d[prop] = slice.call(val); - } else if(utils.isObject(val)) { + } else if(utils.isPlainObject(val)) { d[prop] = utils.extend({}, val, deep, set); } else { d[prop] = s[prop]; @@ -84,6 +84,10 @@ var utils = { isObject: function(obj){ return typeof obj === "object"; }, + isPlainObject: function(obj){ + // A plain object has a proto that is the Object + return utils.isObject(obj) && (!obj || obj.__proto__ === Object.prototype); + }, isArray: Array.isArray || function(arr){ return Object.prototype.toString.call(arr) === "[object Array]"; }, diff --git a/package.json b/package.json index eb126f5cf..ff33215bc 100644 --- a/package.json +++ b/package.json @@ -53,7 +53,7 @@ "saucelabs": "^1.3.0", "steal-env": "^1.0.0", "steal-es6-module-loader": "0.17.14", - "steal-npm": "1.0.5", + "steal-npm": "1.0.6", "steal-qunit": "^1.0.0", "system-bower": "stealjs/system-bower#v0.2.1", "system-live-reload": "1.5.3",