mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 12:07:55 +00:00
Fixes #1619 - Remove push notification registration on logout
This commit is contained in:
committed by
Stefan Ceriu
parent
ab1c7c1c9a
commit
259baeaf99
@@ -527,11 +527,13 @@ class AppCoordinator: AppCoordinatorProtocol, AuthenticationCoordinatorDelegate,
|
||||
return
|
||||
}
|
||||
|
||||
// The user will log out, clear any existing notifications
|
||||
// The user will log out, clear any existing notifications and unregister from receving new ones
|
||||
UNUserNotificationCenter.current().removeAllPendingNotificationRequests()
|
||||
UNUserNotificationCenter.current().removeAllDeliveredNotifications()
|
||||
UIApplication.shared.applicationIconBadgeNumber = 0
|
||||
|
||||
unregisterForRemoteNotifications()
|
||||
|
||||
Task {
|
||||
// First log out from the server
|
||||
let accountLogoutURL = await userSession.clientProxy.logout()
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
Remove push notification registration on logout
|
||||
Reference in New Issue
Block a user