File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -35,12 +35,13 @@ - (void)populateNotificationContent:(UNMutableNotificationContent *)content
3535 self.contentHandler = [contentHandler copy ];
3636 self.bestAttemptContent = content;
3737
38- NSString *currentImageURL = content.userInfo [kPayloadOptionsName ][kPayloadOptionsImageURLName ];
38+ // The `userInfo` property isn't available on newer versions of tvOS.
39+ #if TARGET_OS_IOS || TARGET_OS_OSX
40+ NSString *currentImageURL = content.userInfo [kPayloadOptionsName ][kPayloadOptionsImageURLName ];
3941 if (!currentImageURL) {
4042 [self deliverNotification ];
4143 return ;
4244 }
43- #if TARGET_OS_IOS || TARGET_OS_OSX
4445 NSURL *attachmentURL = [NSURL URLWithString: currentImageURL];
4546 if (attachmentURL) {
4647 [self loadAttachmentForURL: attachmentURL
You can’t perform that action at this time.
0 commit comments