Created
April 1, 2016 18:02
-
-
Save kwylez/08c9079b08d118f7d9feb7db0f3672fc 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
- (void)executeLocalNotificationWithLaunchHookKey:(NSString *)launchHookKey | |
hookType:(RTVNotificationHookType)hookType | |
userInfo:(NSDictionary *)userInfo { | |
NSDictionary *dict = [self.notificationConfiguration notificationHooks]; | |
NSSet *notificationIgnoreTypes = [self.notificationConfiguration notificationTypesToIgnore]; | |
[dict enumerateKeysAndObjectsUsingBlock:^(NSString *key, id hook, BOOL *stop) { | |
if ([key isEqualToString:launchHookKey] && ![notificationIgnoreTypes containsObject:key]) { | |
void (^hookBlock)(NSDictionary *userInfo, RTVNotificationHookType hookType) = dict[key]; | |
hookBlock(userInfo, hookType); | |
*stop = YES; | |
} | |
}]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment