Skip to content

Commit 6854b7a

Browse files
Remove fatalError and replace with print
1 parent 860806d commit 6854b7a

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

sample-apps/swiftui-sample-app/swiftui-sample-app/MainApp.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import SwiftUI
44
struct MainApp: App {
55
@UIApplicationDelegateAdaptor
66
private var appDelegate: AppDelegate
7-
7+
88
var body: some Scene {
99
WindowGroup {
1010
ContentView()
@@ -18,7 +18,7 @@ class AppDelegate: NSObject, UIApplicationDelegate {
1818
NotificationsHelper.shared.setupNotifications()
1919

2020
IterableHelper.initialize(launchOptions: launchOptions)
21-
21+
2222
return true
2323
}
2424

@@ -29,16 +29,16 @@ class AppDelegate: NSObject, UIApplicationDelegate {
2929
}
3030

3131
func application(_: UIApplication, didRegisterForRemoteNotificationsWithDeviceToken deviceToken: Data) {
32-
IterableHelper.register(token: deviceToken)
32+
IterableHelper.register(token: deviceToken)
3333
}
3434

3535
func application(_ application: UIApplication, didFailToRegisterForRemoteNotificationsWithError error: Error) {
36-
fatalError()
36+
print("Failed to register token: \(error.localizedDescription)")
3737
}
3838

3939
func application(_ application: UIApplication, continue userActivity: NSUserActivity, restorationHandler: @escaping ([UIUserActivityRestoring]?) -> Void) -> Bool {
4040
guard let url = userActivity.webpageURL else {
41-
return false
41+
return false
4242
}
4343

4444
return IterableHelper.handle(universalLink: url)

0 commit comments

Comments
 (0)