Convert to async/await.

This commit is contained in:
Brent Simmons committed 2025-11-10 12:02:01 -08:00
1 parent 143e5e1da8
commit 1b2e2d0513
6 files changed
+46 -33

No files matched your search

@@ -29,9 +29,10 @@ final class AddFolderWindowController : NSWindowController {
}
self.hostWindow = hostWindow
hostWindow.beginSheet(window) { (returnCode: NSApplication.ModalResponse) -> Void in
if returnCode == NSApplication.ModalResponse.OK {
self.addFolderIfNeeded()
Task { @MainActor in
let response = await hostWindow.beginSheet(window)
if response == .OK {
addFolderIfNeeded()
}
}
}