Skip to content

Commit b30eee1

Browse files
committed
fix(messaging, ios): resolve getAPNSToken promise in all cases
Fixes invertase#7272 with thanks to @appa-gomi !
1 parent 73ca3d5 commit b30eee1

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

packages/messaging/ios/RNFBMessaging/RNFBMessagingModule.m

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,9 @@ - (NSDictionary *)constantsToExport {
173173
resolve([NSNull null]);
174174
return;
175175
#endif
176-
DLog(@"RNFBMessaging getAPNSToken - ARM64 Simulator detected, but no APNS token set. Assuming "
177-
@"APNS token is possible. macOS13+ / iOS16+ / M1 mac required for assumption to be valid. "
176+
DLog(@"RNFBMessaging getAPNSToken - ARM64 Simulator detected, but no APNS token available. "
177+
@"APNS token may be possible. macOS13+ / iOS16+ / M1 mac required for assumption to be "
178+
@"valid. "
178179
@"Use setAPNSToken in testing if needed.");
179180
#endif
180181
if ([UIApplication sharedApplication].isRegisteredForRemoteNotifications == NO) {
@@ -188,6 +189,7 @@ - (NSDictionary *)constantsToExport {
188189
}];
189190
return;
190191
}
192+
resolve([NSNull null]);
191193
}
192194
}
193195

0 commit comments

Comments
 (0)