Skip to content

Commit 902a109

Browse files
committed
Remove notification_types from on_session request
* Remove notification_types from SMS and Email on_session request
1 parent 0b780c0 commit 902a109

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed

iOS_SDK/OneSignalSDK/Source/OSUserStateEmailSynchronizer.m

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ - (NSDictionary *)getRegistrationData:(OSUserState *)registrationState {
7979
emailDataDic[@"email_auth_hash"] = self.getEmailAuthHashToken;
8080
emailDataDic[@"identifier"] = _currentEmailSubscriptionState.emailAddress;
8181
emailDataDic[@"device_player_id"] = _currentSubscriptionState.userId;
82+
[emailDataDic removeObjectForKey:@"notification_types"];
8283

8384
// If push device has external id we want to add it to the email device also
8485
if (registrationState.externalUserId)

iOS_SDK/OneSignalSDK/Source/OSUserStateSMSSynchronizer.m

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ - (NSDictionary *)getRegistrationData:(OSUserState *)registrationState {
8383
smsDataDic[SMS_NUMBER_AUTH_HASH_KEY] = self.getSMSAuthHashToken;
8484
smsDataDic[SMS_NUMBER_KEY] = _currentSMSSubscriptionState.smsNumber;
8585
smsDataDic[@"device_player_id"] = _currentSubscriptionState.userId;
86+
[smsDataDic removeObjectForKey:@"notification_types"];
8687

8788
// If push device has external id we want to add it to the SMS device also
8889
if (registrationState.externalUserId)

iOS_SDK/OneSignalSDK/Source/Requests.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,13 @@ NS_ASSUME_NONNULL_BEGIN
6969
NS_ASSUME_NONNULL_END
7070

7171
@interface OSRequestUpdateDeviceToken : OneSignalRequest
72+
// Push channel update device token
7273
+ (instancetype _Nonnull)withUserId:(NSString * _Nonnull)userId appId:(NSString * _Nonnull)appId deviceToken:(NSString * _Nullable)identifier notificationTypes:(NSNumber * _Nullable)notificationTypes externalIdAuthToken:(NSString * _Nullable)externalIdAuthToken;
7374

75+
// Email channel update device token
7476
+ (instancetype _Nonnull)withUserId:(NSString * _Nonnull)userId appId:(NSString * _Nonnull)appId deviceToken:(NSString * _Nullable)identifier withParentId:(NSString * _Nullable)parentId emailAuthToken:(NSString * _Nullable)emailAuthHash email:(NSString * _Nullable)email externalIdAuthToken:(NSString * _Nullable)externalIdAuthToken;
7577

78+
// SMS channel update device token
7679
+ (instancetype _Nonnull)withUserId:(NSString * _Nonnull)userId appId:(NSString * _Nonnull)appId deviceToken:(NSString * _Nullable)identifier smsAuthToken:(NSString * _Nullable)smsAuthToken externalIdAuthToken:(NSString * _Nullable)externalIdAuthToken;
7780
@end
7881

0 commit comments

Comments
 (0)