Skip to content

Commit

Permalink
Tweaked for structured concurrency.
Browse files Browse the repository at this point in the history
  • Loading branch information
grigorye committed Jun 25, 2023
1 parent a9ab1a8 commit 83e32ce
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import SwiftUI
@available(macOS 11.0, *)
struct FolderListView: View {

init(urls: [URL], selection: Set<URL> = [], handleFileDrop: @escaping ([NSItemProvider]) -> Bool, removeURLs: @escaping ([URL]) -> Void) {
init(urls: [URL], selection: Set<URL> = [], handleFileDrop: @escaping @MainActor ([NSItemProvider]) -> Bool, removeURLs: @escaping ([URL]) -> Void) {
self.urls = urls
self.selection = selection
self.handleFileDrop = handleFileDrop
Expand All @@ -15,7 +15,7 @@ struct FolderListView: View {
@SwiftUI.State var selection: Set<URL> = []
@SwiftUI.State private var dragOver = false

private let handleFileDrop: ([NSItemProvider]) -> Bool
private let handleFileDrop: @MainActor ([NSItemProvider]) -> Bool
private let removeURLs: ([URL]) -> Void

var body: some View {
Expand Down

0 comments on commit 83e32ce

Please sign in to comment.