-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support backup Firefox extension https://addons.mozilla.org/en-US/fir…
- Loading branch information
Showing
1 changed file
with
5 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -195,6 +195,9 @@ pub fn find_firefox_profiles( | |
|
||
// has "open-url-in-container" extension installed, which adds "ext+container" protocol support | ||
fn has_open_url_in_container_extension_installed(extensions_json_file_path: &Path) -> bool { | ||
let extension_id = "{f069aec0-43c5-4bbf-b6b4-df95c4326b98}"; | ||
let extension2_id = "[email protected]"; | ||
|
||
// Open the file in read-only mode with buffer. | ||
let file = File::open(extensions_json_file_path).unwrap(); | ||
let reader = BufReader::new(file); | ||
|
@@ -204,8 +207,8 @@ fn has_open_url_in_container_extension_installed(extensions_json_file_path: &Pat | |
for addon in addons_arr { | ||
let addon_id = addon["id"].as_str().unwrap(); | ||
// https://addons.mozilla.org/en-US/firefox/addon/open-url-in-container/ | ||
let extension_id = "{f069aec0-43c5-4bbf-b6b4-df95c4326b98}"; | ||
if addon_id == extension_id { | ||
|
||
if addon_id == extension_id || addon_id == extension2_id { | ||
let is_active = addon["active"].as_bool().unwrap(); | ||
return is_active; | ||
} | ||
|