Skip to content

Commit cc09823

Browse files
committed
[Messaging] Delete variable (#1784)
1 parent 8cfb190 commit cc09823

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

messaging/MessagingExampleSwift/AppDelegate.swift

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -118,16 +118,13 @@ extension AppDelegate: UNUserNotificationCenterDelegate {
118118
// Print full message.
119119
print(userInfo)
120120

121-
// Change options to your preferred presentation option
121+
// Change this to your preferred presentation option
122122
// Note: UNNotificationPresentationOptions.alert has been deprecated.
123-
let options: UNNotificationPresentationOptions
124123
if #available(iOS 14.0, *) {
125-
options = [.list, .banner, .sound]
124+
return [.list, .banner, .sound]
126125
} else {
127-
options = [.alert, .sound]
126+
return [.alert, .sound]
128127
}
129-
130-
return options
131128
}
132129

133130
func userNotificationCenter(_ center: UNUserNotificationCenter,

0 commit comments

Comments
 (0)