From e7c57052fa63eefeec655c13d0f5c160b5597afc Mon Sep 17 00:00:00 2001 From: anekos Date: Tue, 3 Feb 2009 20:08:00 +0900 Subject: [PATCH] Fix: commands.parseArgs raises "Invalid option: .." Error. When command(:foo) has NOARG option(-bar), ":foo -bar" raises the error. --- common/content/commands.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/content/commands.js b/common/content/commands.js index 170568b1..d6417a23 100644 --- a/common/content/commands.js +++ b/common/content/commands.js @@ -573,7 +573,7 @@ function Commands() //{{{ count++; // to compensate the "=" character } - else if (!/\s/.test(sep)) // this isn't really an option as it has trailing characters, parse it as an argument + else if (!/\s/.test(sep) && sep != undefined) // this isn't really an option as it has trailing characters, parse it as an argument { invalid = true; }