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

userConfig service worker param fix #858

Merged
merged 2 commits into from Sep 20, 2021
Merged

userConfig service worker param fix #858

merged 2 commits into from Sep 20, 2021

Conversation

rgomezp
Copy link
Contributor

@rgomezp rgomezp commented Sep 16, 2021

This PR makes use of the userConfig versions of the Service Worker config parameters which were previously unused. This is crucial to easily support non-root scope integrations when using the web-shim distributions.

See commits for details.


This change is Reviewable

@rgomezp rgomezp force-pushed the serviceWorkerParam-fix branch 5 times, most recently from 4483e84 to 9ac32f8 Compare September 18, 2021 00:09
@rgomezp rgomezp changed the title Service worker param fix userConfig service worker param fix Sep 20, 2021
- This change should work because this point in the codepath should guarantee that the `OneSignal` object is defined (config helper is called after initialization)
- We give preference to the `userConfig` version of the param over the
top-level parameter since the top-level is assigned a default value when
it is initialized. The `userConfig` version would only exist if
explicitly passed in
Copy link
Member

@jkasten2 jkasten2 left a comment

Choose a reason for hiding this comment

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

Reviewed 2 of 2 files at r1, 1 of 1 files at r2, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @rgomezp)

@rgomezp rgomezp merged commit 587f09c into main Sep 20, 2021
@rgomezp rgomezp deleted the serviceWorkerParam-fix branch September 20, 2021 20:20
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.

None yet

2 participants