use Ox.contains

This commit is contained in:
rolux 2012-05-24 19:22:57 +02:00
parent 544e117cb3
commit d5a2588a1e
2 changed files with 1 additions and 2 deletions

View file

@ -65,7 +65,6 @@ Ox.identity = function(val) {
Ox.noop <f> Returns undefined and calls optional callback without arguments
This can be used to combine a synchronous and an asynchronous code path.
@*/
// IE 8 doesn't like `Ox.void`
Ox.noop = function(callback) {
Ox.isFunction(callback) && callback();
};

View file

@ -7,7 +7,7 @@ Ox.checkType <f> Throws a TypeError if a value is not of a given type
type <s|[s]> Type, or array of types
@*/
Ox.checkType = function(val, type) {
if (!Ox.in(Ox.makeArray(type), Ox.typeOf(val))) {
if (!Ox.contains(Ox.makeArray(type), Ox.typeOf(val))) {
throw new TypeError();
}
};