summaryrefslogtreecommitdiffstats
path: root/netwerk/test/unit/test_idn_urls.js
diff options
context:
space:
mode:
authorMoonchild <mcwerewolf@wolfbeast.com>2019-04-20 11:17:30 +0200
committerGitHub <noreply@github.com>2019-04-20 11:17:30 +0200
commite0116ac2b78eb4e621a4d0769e01f8358a6d661c (patch)
treefe2898874f0be34a8425281ecba2cb8cb59fb210 /netwerk/test/unit/test_idn_urls.js
parent32577bdb3d2471c0e5ce4cfd0501a820157230cb (diff)
parent21b4cb27cabecdb5580c01891801c9259689ec87 (diff)
downloadUXP-e0116ac2b78eb4e621a4d0769e01f8358a6d661c.tar
UXP-e0116ac2b78eb4e621a4d0769e01f8358a6d661c.tar.gz
UXP-e0116ac2b78eb4e621a4d0769e01f8358a6d661c.tar.lz
UXP-e0116ac2b78eb4e621a4d0769e01f8358a6d661c.tar.xz
UXP-e0116ac2b78eb4e621a4d0769e01f8358a6d661c.zip
Merge pull request #1041 from Ascrod/default-pref
Clean up try/catch blocks for preferences
Diffstat (limited to 'netwerk/test/unit/test_idn_urls.js')
-rw-r--r--netwerk/test/unit/test_idn_urls.js7
1 files changed, 1 insertions, 6 deletions
diff --git a/netwerk/test/unit/test_idn_urls.js b/netwerk/test/unit/test_idn_urls.js
index 06a53032b..358854093 100644
--- a/netwerk/test/unit/test_idn_urls.js
+++ b/netwerk/test/unit/test_idn_urls.js
@@ -295,12 +295,7 @@ const profiles = ["ASCII", "high", "moderate"];
function run_test() {
var pbi = Cc["@mozilla.org/preferences-service;1"].getService(Ci.nsIPrefBranch);
var oldProfile = pbi.getCharPref("network.IDN.restriction_profile", "moderate");
- var oldWhiteListCom;
- try {
- oldWhitelistCom = pbi.getBoolPref("network.IDN.whitelist.com");
- } catch(e) {
- oldWhitelistCom = false;
- }
+ var oldWhitelistCom = pbi.getBoolPref("network.IDN.whitelist.com", false);
var idnService = Cc["@mozilla.org/network/idn-service;1"].getService(Ci.nsIIDNService);
for (var i = 0; i < profiles.length; ++i) {