Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Update share one object for check type.
  • Loading branch information
hotoo committed Sep 9, 2014
1 parent 3d3c3bc commit 6d76e20
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/util-lang.js
Expand Up @@ -2,9 +2,11 @@
* util-lang.js - The minimal language enhancement
*/

var _object = {}

function isType(type) {
return function(obj) {
return {}.toString.call(obj) == "[object " + type + "]"
return _object.toString.call(obj) == "[object " + type + "]"
}
}

Expand All @@ -17,4 +19,3 @@ var _cid = 0
function cid() {
return _cid++
}

0 comments on commit 6d76e20

Please sign in to comment.