Created
July 10, 2019 07:23
-
-
Save kmuralidharan91/68619d6e359ab778879d416e0d7b906e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
switch userNotificationsAuthorizationStatus { | |
case .notDetermined: | |
requestPermission() | |
case .authorized, .denied, .provisional: | |
fallthrough | |
@unknown default: | |
// No need to request permission. | |
print("Didn't request permission for User Notifications") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment