ios: fix iOS 15 crash when importing chat database (#6068)

This commit is contained in:
Evgeny authored and GitHub committed 2025-07-14 12:46:15 +01:00
1 parent 45c6524c24
commit ed536c9f80
1 file changed
+1 -1
@@ -97,7 +97,7 @@ struct UserPicker: View {
}
.onAppear {
// This check prevents the call of listUsers after the app is suspended, and the database is closed.
if case .active = scenePhase {
if case .active = scenePhase, hasChatCtrl() {
currentUser = m.currentUser?.userId
Task {
do {