From f97eeb6e5d696c0effe7c172621ba3b0d770f627 Mon Sep 17 00:00:00 2001 From: Corey Johnson Date: Wed, 23 Nov 2011 11:05:21 -0500 Subject: [PATCH] key-bindings that do not load get a warning --- src/stdlib/key-binder.coffee | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/stdlib/key-binder.coffee b/src/stdlib/key-binder.coffee index b5d1245ec..98a89ef30 100644 --- a/src/stdlib/key-binder.coffee +++ b/src/stdlib/key-binder.coffee @@ -10,14 +10,13 @@ class KeyBinder constructor: -> @load require.resolve "key-bindings.coffee" - if fs.isFile "~/.atomicity/key-bindings.coffee" - @load "~/.atomicity/key-bindings.coffee" - - register: (name, scope) -> + @load "~/.atomicity/key-bindings.coffee" load: (path) -> path = require.resolve path - return if not fs.isFile path + if not fs.isFile path + console.warn "Could not find keyBinding file '#{path}'" + return try # Watcher.watch path, =>