7 lines
130 B
CoffeeScript
7 lines
130 B
CoffeeScript
|
|
# throw error if time limit has been exceeded
|
|
|
|
module.exports = (limit, msg) ->
|
|
|
|
if Date.now() > limit
|
|
throw new Error msg
|