1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-22 21:37:58 +01:00

Remove an unnecessary localized message to string conversion.

Messages is now JSON aware.
This commit is contained in:
Doug Kearns
2015-05-11 23:19:48 +10:00
parent 29228527c2
commit a8e70d3f43

View File

@@ -1128,7 +1128,7 @@ var Util = Module("Util", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReference]),
if (~["boolean", "number"].indexOf(typeof data) || data === null)
res.push(String(data));
else if (isinstance(data, ["String", _]))
res.push(JSON.stringify(String(data)));
res.push(JSON.stringify(data));
else if (isArray(data)) {
if (data.length == 0)
res.push("[]");