mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-23 22:02:26 +01:00
fix typo in parseArgs#quoteArg
This commit is contained in:
@@ -355,12 +355,12 @@ function Commands() //{{{
|
||||
switch (quote)
|
||||
{
|
||||
case "'":
|
||||
return function (str) "'" + str.substitute(/[\\']/g, "\\$&") + "'";
|
||||
return function (str) "'" + str.replace(/[\\']/g, "\\$&") + "'";
|
||||
case '"':
|
||||
return function (str) '"' + str.substitute(/[\\"\t\n]/g,
|
||||
return function (str) '"' + str.replace(/[\\"\t\n]/g,
|
||||
function (c) (c == "\n" ? "\\n" : c == "\t" ? "\\t" : "\\" + c));
|
||||
default:
|
||||
return function (str) str.substitute(/[\\ ]/g, "\\$&");
|
||||
return function (str) str.replace(/[\\ ]/g, "\\$&");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user