diff --git a/index.js b/index.js index 54f937d..6abc392 100644 --- a/index.js +++ b/index.js @@ -15,8 +15,7 @@ * */ - -var expand = function(keyChain) +module.exports = function(keyChain) { var newArray = []; if(Array.isArray(keyChain)) @@ -24,7 +23,7 @@ var expand = function(keyChain) for(var i = 0; i < keyChain.length; i++) { var value = keyChain[i]; - if(angular.isString(value)) + if(typeof value === 'string') { if(value.indexOf(".") != -1) { @@ -41,11 +40,9 @@ var expand = function(keyChain) } } } - else if(angular.isString(keyChain)) + else if(typeof keyChain === 'string') { newArray = keyChain.split("."); } return newArray; }; - -module.exports = expand; diff --git a/package.json b/package.json index df2f8e4..910e96c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "geodash-expand", - "version": "0.0.1", + "version": "0.0.2", "description": "The `expand` function for [GeoDash](http://geodash.io) that is used during building and runtime.", "keywords": [ "map", @@ -12,7 +12,7 @@ "scripts": { "build:docs": "mkdir docs; gulp docs", "build": "npm run build:docs", - "jshint": "jshint src", + "jshint": "jshint index.js", "tests": "npm run jshint" }, "repository": {