You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Motivation: Hydrating the push subscription is problematic. We will hydrate it if:
- the push subscription ID does not already exist locally
- the type of the returned subscription is iOSPush
- the token at the time the request is made matches the returned token
- we hydrate using the first matching subscription that is returned (there may be multiple iOS push subscriptions in the response but we will accept the first one that fulfills our conditions above)
* This can still be faulty behavior but we get as close as we can to correct behavior for now.
Copy file name to clipboardExpand all lines: iOS_SDK/OneSignalSDK/OneSignalUser/Source/OSUserRequests.swift
+26-19Lines changed: 26 additions & 19 deletions
Original file line number
Diff line number
Diff line change
@@ -63,26 +63,31 @@ class OSUserExecutor {
63
63
}
64
64
65
65
/**
66
-
Used to parse Create User and Fetch User responses.
66
+
Used to parse Create User and Fetch User responses. The `originalPushToken` is the push token when the request was created, which may be different from the push token currently in the SDK (How again can that happen?). This is used to determine whether or not to hydrate the push subscription.
0 commit comments