fix(api): fix onesignal ios_badgeCount and ios_badgeType typos #7273
+13
−16
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What changed? Why was the change needed?
fixes #7199
Hi all
We were debugging some things and noticed the following:
In both, the old and new OneSignal API, the keys for
ios_badge_type
andios_badge_count
is defined as:ios_badgeType
ios_badgeCount
New API: https://documentation.onesignal.com/reference/push-notification
Old API: https://documentation.onesignal.com/v9.0/reference/push-channel-properties
In the Novu code, the following are used:
ios_badge_type
ios_badge_count
Questions:
1. What is
protected keyCaseObject: Record<string, string> = {
?Does the
this.transform function
, change any of the keys? Is it related toprotected keyCaseObject: Record<string, string> = {
Because in
protected keyCaseObject
we useios_badgeType
andios_badgeCount
:packages/providers/src/lib/push/one-signal/one-signal.provider.ts
2 Duplicate Keys
Why are both keys in the unit test
ios_badgeCount
andios_badge_count
?packages/providers/src/lib/push/one-signal/one-signal.provider.spec.ts
Expand for optional sections
Related enterprise PR
Special notes for your reviewer