v1.0.6
This commit is contained in:
parent
3e66d00607
commit
e91991c4db
|
@ -3,6 +3,7 @@
|
||||||
"contributors": [ "Douglas Crockford <douglas@crockford.com>" ],
|
"contributors": [ "Douglas Crockford <douglas@crockford.com>" ],
|
||||||
"dependencies": {},
|
"dependencies": {},
|
||||||
"description": "Deprecated. Utilities for ES3, most of which have been adopted or superseded in ES5.1. Adapted from Douglas Crockford's Remedial JavaScript",
|
"description": "Deprecated. Utilities for ES3, most of which have been adopted or superseded in ES5.1. Adapted from Douglas Crockford's Remedial JavaScript",
|
||||||
|
"homepage": "https://git.coolaj86.com/coolaj86/remedial.js",
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": "*"
|
"node": "*"
|
||||||
},
|
},
|
||||||
|
@ -15,9 +16,7 @@
|
||||||
"supplant",
|
"supplant",
|
||||||
"trim"
|
"trim"
|
||||||
],
|
],
|
||||||
"lib": "lib",
|
"main": "./remedial",
|
||||||
"main": "./lib/remedial",
|
|
||||||
"name": "remedial",
|
"name": "remedial",
|
||||||
"homepage": "https://git.coolaj86.com/coolaj86/remedial.js",
|
"version": "1.0.6"
|
||||||
"version": "1.0.5"
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,9 +10,11 @@ var provide = provide || function () {},
|
||||||
class2type = {};
|
class2type = {};
|
||||||
|
|
||||||
for (i in classes) {
|
for (i in classes) {
|
||||||
|
if (classes.hasOwnProperty(i)) {
|
||||||
name = classes[i];
|
name = classes[i];
|
||||||
class2type["[object " + name + "]"] = name.toLowerCase();
|
class2type["[object " + name + "]"] = name.toLowerCase();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function typeOf(obj) {
|
function typeOf(obj) {
|
||||||
return (null === obj || undefined === obj) ? String(obj) : class2type[Object.prototype.toString.call(obj)] || "object";
|
return (null === obj || undefined === obj) ? String(obj) : class2type[Object.prototype.toString.call(obj)] || "object";
|
Loading…
Reference in New Issue