Skip to content

Commit 54cc50d

Browse files
committed
Bug 1749345 - Skip FirstStartup initting if a previous profile exists. r=nalexander,rhelmer
The thinking here being that if a previous profile exists, then the --first-startup argument is probably be passed because the user is reinstalling on a system that still has (or once had) the browser already installed on it. In that case, we're going to use that pre-existing profile, and we don't need to do the FirstStartup things, since they're primarily for systems where a new profile is being created after install. Differential Revision: https://phabricator.services.mozilla.com/D199763
1 parent a99e107 commit 54cc50d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

browser/components/BrowserContentHandler.sys.mjs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -663,7 +663,10 @@ nsBrowserContentHandler.prototype = {
663663
}
664664

665665
if (cmdLine.handleFlag("first-startup", false)) {
666-
lazy.FirstStartup.init();
666+
let override = needHomepageOverride(Services.prefs);
667+
if (override == OVERRIDE_NEW_PROFILE) {
668+
lazy.FirstStartup.init();
669+
}
667670
}
668671

669672
var fileParam = cmdLine.handleFlagWithParam("file", false);

0 commit comments

Comments
 (0)