mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-20 11:18:00 +01:00
Fix command spec parsing.
"!" is a valid command name. --HG-- extra : rebase_source : 3c99e0524fb81b84ebcf1546026fcb102ec9c6c7
This commit is contained in:
@@ -224,7 +224,7 @@ const Command = Class("Command", {
|
|||||||
*/
|
*/
|
||||||
parseSpecs: function parseSpecs(specs) {
|
parseSpecs: function parseSpecs(specs) {
|
||||||
return specs.map(function (spec) {
|
return specs.map(function (spec) {
|
||||||
let [, head, tail] = spec.match(/(\w+)(?:\[(.*)])?/);
|
let [, head, tail] = spec.match(/([^[]+)(?:\[(.*)])?/);
|
||||||
return tail ? [head + tail, head] : [head];
|
return tail ? [head + tail, head] : [head];
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user