diff options
| -rw-r--r-- | content_scripts/mode_key_handler.coffee | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/content_scripts/mode_key_handler.coffee b/content_scripts/mode_key_handler.coffee index 0b8145fc..6b6e4f0a 100644 --- a/content_scripts/mode_key_handler.coffee +++ b/content_scripts/mode_key_handler.coffee @@ -96,8 +96,8 @@ class KeyHandlerMode extends Mode @countPrefix = 0 unless keyChar of @keyState[0] # Advance the key state. The new key state is the current mappings of keyChar, plus @keyMapping. @keyState = [(mapping[keyChar] for mapping in @keyState when keyChar of mapping)..., @keyMapping] - command = (mapping for mapping in @keyState when "command" of mapping)[0] - if command + if @keyState[0].command? + command = @keyState[0] count = if 0 < @countPrefix then @countPrefix else 1 bgLog "Call #{command.command}[#{count}] (#{@name})" @reset() |
