Use browser agent UA for image and theme downloads. Fixes #4868.

This commit is contained in:
Brent Simmons committed 2026-07-29 10:17:31 -07:00
1 parent 8b89354eb5
commit 75755af700
15 files changed
+146 -78

No files matched your search

+1 -15
View File
@@ -61,21 +61,7 @@ extension AppDelegate: AppDelegateAppleEvents {
}
if let themeURL = URL(string: themeURLString) {
let request = URLRequest(url: themeURL)
let task = URLSession.shared.downloadTask(with: request) { location, _, error in
guard let location = location else {
return
}
Task { @MainActor in
do {
try ArticleThemeDownloader.shared.handleFile(at: location)
} catch {
NotificationCenter.default.post(name: .didFailToImportThemeWithError, object: nil, userInfo: ["error": error])
}
}
}
task.resume()
ArticleThemeDownloader.shared.downloadTheme(from: themeURL)
}
return
}