зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1667455 - Part 22: Make httpd.js compatible both with patched and unpatched binary (hostutils). r=kmag,necko-reviewers,dragana
Differential Revision: https://phabricator.services.mozilla.com/D150913
This commit is contained in:
Родитель
9fe5b851ea
Коммит
601a003c2c
|
@ -49,7 +49,12 @@ var DEBUG = false; // non-const *only* so tweakable in server tests
|
|||
/** True if debugging output should be timestamped. */
|
||||
var DEBUG_TIMESTAMP = false; // non-const so tweakable in server tests
|
||||
|
||||
const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
||||
// httpd.js is loaded by Android hostutils that's not up to date.
|
||||
// Fallback to Services.jsm if `Services` global variable isn't yet available.
|
||||
const Services =
|
||||
globalThis.Services ||
|
||||
ChromeUtils.import("resource://gre/modules/Services.jsm").Services;
|
||||
|
||||
const { AppConstants } = ChromeUtils.import(
|
||||
"resource://gre/modules/AppConstants.jsm"
|
||||
);
|
||||
|
|
Загрузка…
Ссылка в новой задаче