Skip to content

Commit

Permalink
fix: background double init
Browse files Browse the repository at this point in the history
  • Loading branch information
kvhnuke committed Jul 30, 2024
1 parent 6c610f0 commit 8415a63
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/extension-bridge/src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ export const getBackgroundPageType = (): RuntimeContext => {
const url = new URL(browser.runtime.getURL(manifest.options_ui.page));
if (url.pathname === window.location.pathname) return "options";
}
if (window?.location?.pathname === "/index.html") {
if (
window?.location?.pathname === "/index.html" ||
window?.location?.pathname === "/onboard.html"
) {
return "new-window";
}
return "background";
Expand Down

1 comment on commit 8415a63

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.