From b4eb7140f5cf4f567c83f7af952b09e8bc80918d Mon Sep 17 00:00:00 2001 From: Stephen Blott Date: Sun, 11 Dec 2016 15:27:06 +0000 Subject: Add the raw option list to the command registry. Keep the option list (in addition to the parsed command options) because some commands may depend upon the command option order. One currect example is #2318. --- background_scripts/commands.coffee | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'background_scripts') diff --git a/background_scripts/commands.coffee b/background_scripts/commands.coffee index aece4bec..a323b46f 100644 --- a/background_scripts/commands.coffee +++ b/background_scripts/commands.coffee @@ -24,12 +24,12 @@ Commands = switch tokens[0] when "map" if 3 <= tokens.length and not unmapAll - [_, key, command, optionsList...] = tokens + [_, key, command, optionList...] = tokens if not seen[key] and registryEntry = @availableCommands[command] seen[key] = true keySequence = @parseKeySequence key - options = @parseCommandOptions command, optionsList - @keyToCommandRegistry[key] = extend {keySequence, command, options}, @availableCommands[command] + options = @parseCommandOptions command, optionList + @keyToCommandRegistry[key] = extend {keySequence, command, options, optionList}, @availableCommands[command] when "unmap" if tokens.length == 2 seen[tokens[1]] = true -- cgit v1.2.3