mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-05-07 08:27:41 +02:00
Merge pull request #2582 from vector-im/riot_2348
Push: Update code to follow API break
This commit is contained in:
+1
-1
@@ -2742,7 +2742,7 @@ NSString *const kAppDelegateNetworkStatusDidChangeNotification = @"kAppDelegateN
|
||||
if (isPushRegistered)
|
||||
{
|
||||
// Enable push notifications by default on new added account
|
||||
account.enablePushKitNotifications = YES;
|
||||
[account enablePushKitNotifications:YES success:nil failure:nil];
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -2874,7 +2874,11 @@ SignOutAlertPresenterDelegate>
|
||||
|
||||
if (accountManager.pushDeviceToken)
|
||||
{
|
||||
[account setEnablePushKitNotifications:!account.isPushKitNotificationActive];
|
||||
[account enablePushKitNotifications:!account.isPushKitNotificationActive success:^{
|
||||
[self stopActivityIndicator];
|
||||
} failure:^(NSError *error) {
|
||||
[self stopActivityIndicator];
|
||||
}];
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -2887,7 +2891,11 @@ SignOutAlertPresenterDelegate>
|
||||
}
|
||||
else
|
||||
{
|
||||
[account setEnablePushKitNotifications:YES];
|
||||
[account enablePushKitNotifications:YES success:^{
|
||||
[self stopActivityIndicator];
|
||||
} failure:^(NSError *error) {
|
||||
[self stopActivityIndicator];
|
||||
}];
|
||||
}
|
||||
}];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user