mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-16 18:45:46 +01:00
Fix complex 'passkeys' serialization.
This commit is contained in:
@@ -431,12 +431,14 @@ var Option = Class("Option", {
|
|||||||
let [, bang, filter] = /^(!?)(.*)/.exec(pattern);
|
let [, bang, filter] = /^(!?)(.*)/.exec(pattern);
|
||||||
filter = Option.dequote(filter);
|
filter = Option.dequote(filter);
|
||||||
|
|
||||||
|
let quote = this.keepQuotes ? util.identity : Option.quote;
|
||||||
|
|
||||||
return update(Styles.matchFilter(filter), {
|
return update(Styles.matchFilter(filter), {
|
||||||
bang: bang,
|
bang: bang,
|
||||||
filter: filter,
|
filter: filter,
|
||||||
result: result !== undefined ? result : !bang,
|
result: result !== undefined ? result : !bang,
|
||||||
toString: function toString() this.bang + Option.quote(this.filter) +
|
toString: function toString() this.bang + Option.quote(this.filter) +
|
||||||
(typeof this.result === "boolean" ? "" : ":" + Option.quote(this.result)),
|
(typeof this.result === "boolean" ? "" : ":" + quote(this.result)),
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
@@ -492,7 +494,7 @@ var Option = Class("Option", {
|
|||||||
return [];
|
return [];
|
||||||
if (!isArray(value))
|
if (!isArray(value))
|
||||||
value = Option.splitList(value, true);
|
value = Option.splitList(value, true);
|
||||||
return value.map(Option.parseSite);
|
return value.map(Option.parseSite, this);
|
||||||
},
|
},
|
||||||
|
|
||||||
stringmap: function stringmap(value) array.toObject(
|
stringmap: function stringmap(value) array.toObject(
|
||||||
|
|||||||
@@ -296,7 +296,7 @@ var File = Class("File", {
|
|||||||
if (path instanceof Ci.nsIFile)
|
if (path instanceof Ci.nsIFile)
|
||||||
file = path.clone();
|
file = path.clone();
|
||||||
else if (/file:\/\//.test(path))
|
else if (/file:\/\//.test(path))
|
||||||
file = services["file:"]().getFileFromURLSpec(path);
|
file = services["file:"].getFileFromURLSpec(path);
|
||||||
else {
|
else {
|
||||||
try {
|
try {
|
||||||
let expandedPath = File.expandPath(path);
|
let expandedPath = File.expandPath(path);
|
||||||
|
|||||||
Reference in New Issue
Block a user