Skip to content
Snippets Groups Projects
Verified Commit 2348214b authored by Pier Angelo Vendrame's avatar Pier Angelo Vendrame :jack_o_lantern:
Browse files

fixup! Bug 40597: Implement TorSettings module

Do not freeze TorConnectError.
parent b934b41b
No related branches found
No related tags found
1 merge request!1043Bug 42616: Rebased alpha onto Firefox 128.0b1
......@@ -47,12 +47,24 @@ export const TorConnectState = Object.freeze({
});
export class TorConnectError extends Error {
static Offline = "Offline";
static BootstrapError = "BootstrapError";
static CannotDetermineCountry = "CannotDetermineCountry";
static NoSettingsForCountry = "NoSettingsForCountry";
static AllSettingsFailed = "AllSettingsFailed";
static ExternalError = "ExternalError";
static get Offline() {
return "Offline";
}
static get BootstrapError() {
return "BootstrapError";
}
static get CannotDetermineCountry() {
return "CannotDetermineCountry";
}
static get NoSettingsForCountry() {
return "NoSettingsForCountry";
}
static get AllSettingsFailed() {
return "AllSettingsFailed";
}
static get ExternalError() {
return "ExternalError";
}
constructor(code, cause) {
super(cause?.message ?? `TorConnectError: ${code}`, cause ? { cause } : {});
......@@ -60,7 +72,6 @@ export class TorConnectError extends Error {
this.code = code;
}
}
Object.freeze(TorConnectError);
ChromeUtils.defineLazyGetter(
lazy,
......
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment