mirror of
https://github.com/samsonjs/vibetunnel.git
synced 2026-06-28 05:29:29 +00:00
Fix NotificationCenter async sequence usage
Remove incorrect .values accessor - NotificationCenter.Notifications is already an AsyncSequence
This commit is contained in:
parent
f7f5a9e29a
commit
8856916ccc
1 changed files with 2 additions and 1 deletions
|
|
@ -74,7 +74,8 @@ class ServerManager {
|
|||
private func setupObservers() {
|
||||
// Watch for server mode changes when the value actually changes
|
||||
Task { @MainActor in
|
||||
for await _ in NotificationCenter.default.notifications(named: UserDefaults.didChangeNotification).values {
|
||||
let notifications = NotificationCenter.default.notifications(named: UserDefaults.didChangeNotification)
|
||||
for await _ in notifications {
|
||||
await handleServerModeChange()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue