Coffeescript declares variable before assigning it

This commit is contained in:
Cheng Zhao 2015-07-30 10:31:49 +08:00
parent 8d09f13bad
commit 2d5c0ac9ee

View file

@ -1,4 +1,4 @@
global = global # the "global.global" might be deleted later
savedGlobal = global # the "global.global" might be deleted later
module.exports =
class CallbacksRegistry
@ -18,10 +18,10 @@ class CallbacksRegistry
@callbacks[id] ? ->
call: (id, args...) ->
@get(id).call global, args...
@get(id).call savedGlobal, args...
apply: (id, args...) ->
@get(id).apply global, args...
@get(id).apply savedGlobal, args...
remove: (id) ->
delete @callbacks[id]