Skip to content

Commit c84290f

Browse files
committed
fix swift6 context error
1 parent 35d7d34 commit c84290f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Django Files/Utils/DeepLinks.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ class DeepLinks {
1212
static let shared = DeepLinks()
1313
private init() {}
1414

15-
func handleDeepLink(_ url: URL, context: ModelContext, sessionManager: SessionManager, previewStateManager: PreviewStateManager, selectedTab: Binding<TabViewWindow.Tab>, hasExistingSessions: Binding<Bool>, showingServerConfirmation: Binding<Bool>, pendingAuthURL: Binding<URL?>, pendingAuthSignature: Binding<String?>) {
15+
@MainActor func handleDeepLink(_ url: URL, context: ModelContext, sessionManager: SessionManager, previewStateManager: PreviewStateManager, selectedTab: Binding<TabViewWindow.Tab>, hasExistingSessions: Binding<Bool>, showingServerConfirmation: Binding<Bool>, pendingAuthURL: Binding<URL?>, pendingAuthSignature: Binding<String?>) {
1616
print("Deep link received: \(url)")
1717
guard url.scheme == "djangofiles" else { return }
1818

@@ -36,7 +36,7 @@ class DeepLinks {
3636
}
3737
}
3838

39-
private func handlePreviewLink(_ components: URLComponents, context: ModelContext, sessionManager: SessionManager, previewStateManager: PreviewStateManager, selectedTab: Binding<TabViewWindow.Tab>) {
39+
@MainActor private func handlePreviewLink(_ components: URLComponents, context: ModelContext, sessionManager: SessionManager, previewStateManager: PreviewStateManager, selectedTab: Binding<TabViewWindow.Tab>) {
4040
print("🔍 Handling preview deep link with components: \(components)")
4141

4242
guard let urlString = components.queryItems?.first(where: { $0.name == "url" })?.value?.removingPercentEncoding,
@@ -128,7 +128,7 @@ class DeepLinks {
128128
}
129129
}
130130

131-
private func handleFileListDeepLink(_ components: URLComponents, context: ModelContext, sessionManager: SessionManager, selectedTab: Binding<TabViewWindow.Tab>) {
131+
@MainActor private func handleFileListDeepLink(_ components: URLComponents, context: ModelContext, sessionManager: SessionManager, selectedTab: Binding<TabViewWindow.Tab>) {
132132
guard let urlString = components.queryItems?.first(where: { $0.name == "url" })?.value?.removingPercentEncoding,
133133
let serverURL = URL(string: urlString) else {
134134
print("Invalid server URL in filelist deep link")
@@ -154,7 +154,7 @@ class DeepLinks {
154154
}
155155
}
156156

157-
private func deepLinkAuth(_ components: URLComponents, context: ModelContext, sessionManager: SessionManager, hasExistingSessions: Binding<Bool>, showingServerConfirmation: Binding<Bool>, pendingAuthURL: Binding<URL?>, pendingAuthSignature: Binding<String?>) {
157+
@MainActor private func deepLinkAuth(_ components: URLComponents, context: ModelContext, sessionManager: SessionManager, hasExistingSessions: Binding<Bool>, showingServerConfirmation: Binding<Bool>, pendingAuthURL: Binding<URL?>, pendingAuthSignature: Binding<String?>) {
158158
guard let signature = components.queryItems?.first(where: { $0.name == "signature" })?.value?.removingPercentEncoding,
159159
let serverURL = URL(string: components.queryItems?.first(where: { $0.name == "url" })?.value?.removingPercentEncoding ?? "") else {
160160
print("Unable to parse auth deep link.")

0 commit comments

Comments
 (0)