Fix refreshing counter after switching the account
This commit is contained in:
parent
5cc7167336
commit
7e9fd97efd
|
@ -62,7 +62,7 @@ struct VernissageApp: App {
|
|||
}
|
||||
.navigationViewStyle(.stack)
|
||||
.onReceive(NotificationCenter.default.publisher(for: UIApplication.didBecomeActiveNotification)) { _ in
|
||||
DispatchQueue.main.asyncAfter(deadline: .now() + 2) {
|
||||
DispatchQueue.main.asyncAfter(deadline: .now() + 5) {
|
||||
Task {
|
||||
// Refresh indicator of new photos when application is become active.
|
||||
await self.calculateNewPhotosInBackground()
|
||||
|
@ -135,7 +135,7 @@ struct VernissageApp: App {
|
|||
return
|
||||
}
|
||||
|
||||
self.setApplicationState(accountModel: signedInAccountModel)
|
||||
self.setApplicationState(accountModel: signedInAccountModel, checkNewPhotos: true)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue