Skip to content

Commit bb37664

Browse files
committed
Fix linter and upgrade dependencies
1 parent 1bbfd47 commit bb37664

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

WakaTime/AppDelegate.swift

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,8 @@ class AppDelegate: NSObject, NSApplicationDelegate, StatusBarDelegate, UNUserNot
160160
Task.detached(priority: .background) {
161161
self.fetchToday()
162162
}
163-
statusBarItem.popUpMenu(menu)
163+
// statusBarItem.popUpMenu(menu)
164+
statusBarItem.menu = menu
164165
}
165166

166167
func a11yStatusChanged(_ hasPermission: Bool) {
@@ -227,7 +228,11 @@ class AppDelegate: NSObject, NSApplicationDelegate, StatusBarDelegate, UNUserNot
227228
func userNotificationCenter(_ center: UNUserNotificationCenter,
228229
willPresent notification: UNNotification,
229230
withCompletionHandler completionHandler: @escaping (UNNotificationPresentationOptions) -> Void) {
230-
completionHandler([.banner, .sound])
231+
if #available(macOS 11.0, *) {
232+
completionHandler([.banner, .sound])
233+
} else {
234+
completionHandler([.alert, .sound]) // Fallback for older macOS versions
235+
}
231236
}
232237

233238
private func setText(_ text: String) {

project.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ packages:
1010
branch: master
1111
Firebase:
1212
url: https://github.com/firebase/firebase-ios-sdk
13-
from: 10.0.0
13+
from: 11.11.0
1414

1515
targets:
1616
WakaTime:

0 commit comments

Comments
 (0)