[tor-commits] [Git][tpo/applications/tor-browser][tor-browser-115.8.0esr-13.5-1] Bug 42438: Tweaks to the migration wizard.

Pier Angelo Vendrame (@pierov) git at gitlab.torproject.org
Thu Mar 7 09:45:14 UTC 2024



Pier Angelo Vendrame pushed to branch tor-browser-115.8.0esr-13.5-1 at The Tor Project / Applications / Tor Browser


Commits:
a014a0e0 by Pier Angelo Vendrame at 2024-03-07T10:44:55+01:00
Bug 42438: Tweaks to the migration wizard.

Remove the items not compatible with our features (such as history) from
the migration wizard.

On Linux, allow to specify an alternative home directory, since we
usually change $HOME in our startup script.

- - - - -


2 changed files:

- browser/components/migration/ChromeMigrationUtils.sys.mjs
- browser/components/migration/content/migration-wizard.mjs


Changes:

=====================================
browser/components/migration/ChromeMigrationUtils.sys.mjs
=====================================
@@ -317,7 +317,10 @@ export var ChromeMigrationUtils = {
     for (let subfolders of options) {
       let rootDir = subfolders[0];
       try {
-        let targetPath = Services.dirsvc.get(rootDir, Ci.nsIFile).path;
+        let targetPath =
+          rootDir === "Home" && Services.env.get("BB_ORIGINAL_HOME")
+            ? Services.env.get("BB_ORIGINAL_HOME")
+            : Services.dirsvc.get(rootDir, Ci.nsIFile).path;
         targetPath = PathUtils.join(targetPath, ...subfolders.slice(1));
         if (await IOUtils.exists(targetPath)) {
           return targetPath;


=====================================
browser/components/migration/content/migration-wizard.mjs
=====================================
@@ -416,7 +416,10 @@ export class MigrationWizard extends HTMLElement {
     }
 
     let key = panelItem.getAttribute("key");
-    let resourceTypes = panelItem.resourceTypes;
+    const allowedTypes = ["BOOKMARKS"];
+    let resourceTypes = panelItem.resourceTypes.filter(t =>
+      allowedTypes.includes(t)
+    );
 
     for (let child of this.#resourceTypeList.querySelectorAll(
       "label[data-resource-type]"



View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/a014a0e04a39f98378749aa1cb698b07035e9252

-- 
View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser/-/commit/a014a0e04a39f98378749aa1cb698b07035e9252
You're receiving this email because of your account on gitlab.torproject.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.torproject.org/pipermail/tor-commits/attachments/20240307/e0c6ece4/attachment-0001.htm>


More information about the tor-commits mailing list