Created
March 10, 2020 06:35
-
-
Save ITechRoof/c4f2d7813428d5ca4e86366d5b20cf2f to your computer and use it in GitHub Desktop.
User notification request
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
[[UNUserNotificationCenter currentNotificationCenter] requestAuthorizationWithOptions:UNAuthorizationOptionAlert completionHandler:^(BOOL granted, NSError * _Nullable error) { | |
if(!error && granted) | |
{ | |
NSLog(@"REGISTERD"); | |
} | |
}]; | |
[UNUserNotificationCenter currentNotificationCenter].delegate = self; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment