From 2d5c0ac9eebb5bf37de1dcb3375511d6dd6afbab Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Thu, 30 Jul 2015 10:31:49 +0800 Subject: [PATCH] Coffeescript declares variable before assigning it --- atom/common/api/lib/callbacks-registry.coffee | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/atom/common/api/lib/callbacks-registry.coffee b/atom/common/api/lib/callbacks-registry.coffee index 4999e19d..8f5eb629 100644 --- a/atom/common/api/lib/callbacks-registry.coffee +++ b/atom/common/api/lib/callbacks-registry.coffee @@ -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] -- 2.43.0