Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't trigger "InstallTrigger is deprecated and will be removed in the future" warning #4080

Closed
wants to merge 1 commit into from
Closed

Conversation

arp242
Copy link

@arp242 arp242 commented Jul 7, 2022

By checking for presence in window it doesn't trigger the warning, which
is a bit annoying since it's in my console all the time and makes it
harder to see "did the script I'm working on throw a warning/error?" at
a glance.

Furthermore, it also puts back the old check that was removed in #3773;
InstallTrigger will be removed eventually, and it will then break for
everyone. This conditional should probably be updated, but I don't know
what to (and any updated version may have the same issue).

Fixes #4033

…e future" warning

By checking for presence in window it doesn't trigger the warning, which
is a bit annoying since it's in my console all the time and makes it
harder to see "did the script I'm working on throw a warning/error?" at
a glance.

Furthermore, it also puts back the old check that was removed in #3773;
InstallTrigger will be removed eventually, and it will then break for
everyone. This conditional should probably be updated, but I don't know
what to (and any updated version may have the same issue).

Fixes #4033
@gdh1995
Copy link
Contributor

gdh1995 commented Oct 7, 2022

Um, I think a better way to also fix #3773 is check extension URL:

typeof browser === "object" && browser.runtime.getURL("").startsWith("moz")

@philc
Copy link
Owner

philc commented Oct 17, 2022

Closing this in favor of c5f232c. Thanks @gdh1995 for the detection method!

@philc philc closed this Oct 17, 2022
@arp242 arp242 deleted the installtrigger branch October 17, 2022 05:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Firefox warning: InstallTrigger is deprecated and will be removed in the future.
3 participants