From fcf3bf1ba5f29378b323a9cdf8fb20fdbd8eef21 Mon Sep 17 00:00:00 2001 From: Dominik Kapusta Date: Wed, 3 Jan 2024 17:53:33 +0100 Subject: [PATCH] Always use 'sandbox' Application Support directory for Favicons Fetcher --- DuckDuckGo/Sync/SyncBookmarksAdapter.swift | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/DuckDuckGo/Sync/SyncBookmarksAdapter.swift b/DuckDuckGo/Sync/SyncBookmarksAdapter.swift index 977737e029..4a46352150 100644 --- a/DuckDuckGo/Sync/SyncBookmarksAdapter.swift +++ b/DuckDuckGo/Sync/SyncBookmarksAdapter.swift @@ -36,19 +36,6 @@ public class BookmarksFaviconsFetcherErrorHandler: EventMapping BookmarksFaviconsFetcher? { let stateStore: BookmarksFaviconsFetcherStateStore do { - guard let url = FileManager.default.urls(for: .applicationSupportDirectory, in: .userDomainMask).first else { - throw SyncBookmarksAdapterError.unableToAccessFaviconsFetcherStateStoreDirectory - } - stateStore = try BookmarksFaviconsFetcherStateStore(applicationSupportURL: url) + stateStore = try BookmarksFaviconsFetcherStateStore(applicationSupportURL: URL.sandboxApplicationSupportURL) } catch { Pixel.fire(.debug(event: .bookmarksFaviconsFetcherStateStoreInitializationFailed, error: error)) os_log(.error, log: OSLog.sync, "Failed to initialize BookmarksFaviconsFetcherStateStore: %{public}s", String(reflecting: error))