Skip to content

Commit e53c645

Browse files
https://github.com/nextcloud/ios/issues/3197
Signed-off-by: Marino Faggiana <[email protected]>
1 parent c151500 commit e53c645

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

iOSClient/SceneDelegate.swift

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -365,14 +365,16 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate {
365365
}
366366

367367
private func showPrivacyProtectionWindow() {
368-
guard let windowScene = self.window?.windowScene else {
369-
return
370-
}
368+
DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) {
369+
guard let windowScene = self.window?.windowScene else {
370+
return
371+
}
371372

372-
privacyProtectionWindow = UIWindow(windowScene: windowScene)
373-
privacyProtectionWindow?.rootViewController = UIStoryboard(name: "LaunchScreen", bundle: nil).instantiateInitialViewController()
374-
privacyProtectionWindow?.windowLevel = .alert + 1
375-
privacyProtectionWindow?.makeKeyAndVisible()
373+
self.privacyProtectionWindow = UIWindow(windowScene: windowScene)
374+
self.privacyProtectionWindow?.rootViewController = UIStoryboard(name: "LaunchScreen", bundle: nil).instantiateInitialViewController()
375+
self.privacyProtectionWindow?.windowLevel = .alert + 1
376+
self.privacyProtectionWindow?.makeKeyAndVisible()
377+
}
376378
}
377379

378380
private func hidePrivacyProtectionWindow() {

0 commit comments

Comments
 (0)