Remove coercion method use.

This commit is contained in:
John-David Dalton
2017-03-13 20:49:45 -07:00
parent 2f281c68b0
commit bb7c959479
33 changed files with 59 additions and 194 deletions

View File

@@ -1,5 +1,3 @@
import toNumber from './toNumber.js'
/**
* Invokes `func` after `wait` milliseconds. Any additional arguments are
* provided to `func` when it's invoked.
@@ -19,7 +17,7 @@ function delay(func, wait, ...args) {
if (typeof func != 'function') {
throw new TypeError('Expected a function')
}
return setTimeout(func, toNumber(wait) || 0, ...args)
return setTimeout(func, +wait || 0, ...args)
}
export default delay