summaryrefslogtreecommitdiffstats
path: root/netwerk/protocol
diff options
context:
space:
mode:
authorJustOff <Off.Just.Off@gmail.com>2020-03-11 01:07:33 +0200
committerwolfbeast <mcwerewolf@wolfbeast.com>2020-04-14 13:05:25 +0200
commitd2aaa74f31cd93106790d977d424f479cee1389a (patch)
tree65e018394ec42bcf563d775d09ada5c248dd584d /netwerk/protocol
parent702cf4254413a66b23ef5b94279db4270e1e2eba (diff)
downloadUXP-d2aaa74f31cd93106790d977d424f479cee1389a.tar
UXP-d2aaa74f31cd93106790d977d424f479cee1389a.tar.gz
UXP-d2aaa74f31cd93106790d977d424f479cee1389a.tar.lz
UXP-d2aaa74f31cd93106790d977d424f479cee1389a.tar.xz
UXP-d2aaa74f31cd93106790d977d424f479cee1389a.zip
Issue #1053 - Remove no longer used function and modules from `UserAgentUpdates.jsm`
Diffstat (limited to 'netwerk/protocol')
-rw-r--r--netwerk/protocol/http/UserAgentUpdates.jsm30
1 files changed, 0 insertions, 30 deletions
diff --git a/netwerk/protocol/http/UserAgentUpdates.jsm b/netwerk/protocol/http/UserAgentUpdates.jsm
index 4b3ae574a..cd21b78b3 100644
--- a/netwerk/protocol/http/UserAgentUpdates.jsm
+++ b/netwerk/protocol/http/UserAgentUpdates.jsm
@@ -17,15 +17,9 @@ XPCOMUtils.defineLazyModuleGetter(
this, "FileUtils", "resource://gre/modules/FileUtils.jsm");
XPCOMUtils.defineLazyModuleGetter(
- this, "NetUtil", "resource://gre/modules/NetUtil.jsm");
-
-XPCOMUtils.defineLazyModuleGetter(
this, "OS", "resource://gre/modules/osfile.jsm");
XPCOMUtils.defineLazyModuleGetter(
- this, "Promise", "resource://gre/modules/Promise.jsm");
-
-XPCOMUtils.defineLazyModuleGetter(
this, "UpdateUtils", "resource://gre/modules/UpdateUtils.jsm");
XPCOMUtils.defineLazyServiceGetter(
@@ -64,30 +58,6 @@ const PREF_APP_DISTRIBUTION_VERSION = "distribution.version";
var gInitialized = false;
-function readChannel(url) {
- return new Promise((resolve, reject) => {
- try {
- let channel = NetUtil.newChannel({uri: url, loadUsingSystemPrincipal: true});
- channel.contentType = "application/json";
-
- NetUtil.asyncFetch(channel, (inputStream, status) => {
- if (!Components.isSuccessCode(status)) {
- reject();
- return;
- }
-
- let data = JSON.parse(
- NetUtil.readInputStreamToString(inputStream, inputStream.available())
- );
- resolve(data);
- });
- } catch (ex) {
- reject(new Error("UserAgentUpdates: Could not fetch " + url + " " +
- ex + "\n" + ex.stack));
- }
- });
-}
-
this.UserAgentUpdates = {
init: function(callback) {
if (gInitialized) {