appdelegate 优化
This commit is contained in:
parent
b2c7d5e34e
commit
3fadac346c
@ -21,10 +21,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
|
|||||||
|
|
||||||
setConfig()
|
setConfig()
|
||||||
|
|
||||||
Task {
|
self.refreshAppData()
|
||||||
await NRLoginManager.manager.updateUserInfo()
|
|
||||||
}
|
|
||||||
NRIapManager.manager.preloadingProducts()
|
|
||||||
|
|
||||||
self.requestNotificationAuthorization()
|
self.requestNotificationAuthorization()
|
||||||
|
|
||||||
@ -51,11 +48,19 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
Task {
|
self.refreshAppData()
|
||||||
await NRLoginManager.manager.updateUserInfo()
|
}
|
||||||
}
|
|
||||||
NRIapManager.manager.preloadingProducts()
|
}
|
||||||
|
|
||||||
|
private extension AppDelegate {
|
||||||
|
|
||||||
|
/// 刷新应用核心数据(登录态、内购列表等)
|
||||||
|
func refreshAppData() {
|
||||||
|
Task {
|
||||||
|
await NRLoginManager.manager.updateUserInfo()
|
||||||
|
}
|
||||||
|
NRIapManager.manager.preloadingProducts()
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user