Skip to content

Commit

Permalink
Merge pull request #4720 from nextcloud/bugfix/pre-big-sur-compile
Browse files Browse the repository at this point in the history
Use preprocessor directive rather than normal 'if' for UNNotification types
  • Loading branch information
claucambra authored Jul 15, 2022
2 parents 7f40e7e + f8d79c3 commit 3271653
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/gui/systray.mm
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ - (void)userNotificationCenter:(UNUserNotificationCenter *)center
willPresentNotification:(UNNotification *)notification
withCompletionHandler:(void (^)(UNNotificationPresentationOptions options))completionHandler
{
if (@available(macOS 11.0, *)) {
#if __MAC_OS_X_VERSION_MIN_REQUIRED >= 110000
completionHandler(UNNotificationPresentationOptionSound + UNNotificationPresentationOptionBanner);
} else {
#else
completionHandler(UNNotificationPresentationOptionSound + UNNotificationPresentationOptionAlert);
}
#endif
}

- (void)userNotificationCenter:(UNUserNotificationCenter *)center
Expand Down

0 comments on commit 3271653

Please sign in to comment.