fix: Fixed session restore not opening an essential tab on startup, b=(no-bug), c=workspaces

This commit is contained in:
Mr. M
2025-05-11 12:54:19 +02:00
parent 0fb9b51cc9
commit fff86fd068

View File

@@ -880,8 +880,8 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
(await this.#shouldShowTabInCurrentWorkspace(tabs[this._tabToSelect])) &&
tabs[this._tabToSelect] !== this._tabToRemoveForEmpty
) {
this.log(`Found tab to select: ${this._tabToSelect}, ${tabs.length}`);
setTimeout(() => {
this.log(`Found tab to select: ${this._tabToSelect}, ${tabs.length}`);
gBrowser.selectedTab = tabs[this._tabToSelect];
this._removedByStartupPage = true;
gBrowser.removeTab(this._tabToRemoveForEmpty, {
@@ -2440,7 +2440,7 @@ var ZenWorkspaces = new (class extends ZenMultiWindowFeature {
if (containerId) {
// In workspaces with default container: Show essentials that match the container
return tabContextId === containerId;
return tabContextId == containerId;
} else {
// In workspaces without a default container: Show essentials that aren't in container-specific workspaces
// or have usercontextid="0" or no usercontextid