From 329cad97e7b33ac77ea662736ed3aa6a0ce3bd19 Mon Sep 17 00:00:00 2001 From: shannon Date: Thu, 10 Apr 2025 08:23:16 -0400 Subject: [PATCH] Some debug prints for push notification subscriptions --- .../Service/Notification/NotificationService.swift | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/MastodonSDK/Sources/MastodonCore/Service/Notification/NotificationService.swift b/MastodonSDK/Sources/MastodonCore/Service/Notification/NotificationService.swift index bf36aad7d..7fb728bb2 100644 --- a/MastodonSDK/Sources/MastodonCore/Service/Notification/NotificationService.swift +++ b/MastodonSDK/Sources/MastodonCore/Service/Notification/NotificationService.swift @@ -313,8 +313,13 @@ extension NotificationService { } let _ = try await createSubscriptionTask.value accountsSubscribed.append(userAuthBox.globallyUniqueUserIdentifier) +#if DEBUG + print("successful register of push notifications for \(String(describing: userAuthBox.cachedAccount?.displayNameWithFallback))") +#endif } catch { - assertionFailure("error creating push notification subscription") +#if DEBUG + print("failed register of push notifications for \(String(describing: userAuthBox.cachedAccount?.displayNameWithFallback))") +#endif registrationStatus.send(.errorUpdatingSubscriptions(error, deviceToken: deviceToken)) hasNewError = true do {