Skip to content

Commit

Permalink
one more renaming
Browse files Browse the repository at this point in the history
  • Loading branch information
SabrinaTardio committed May 7, 2024
1 parent f8de455 commit 29b988a
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions DuckDuckGo/Sync/SyncBookmarksAdapter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ final class SyncBookmarksAdapter {

private(set) var provider: BookmarksProvider?
let databaseCleaner: BookmarkDatabaseCleaner
let syncAdapterErrorHandler: SyncAdapterErrorHandling
let syncAdapterErrorHandler: SyncErrorHandling

@Published
var isFaviconsFetchingEnabled: Bool = UserDefaultsWrapper(key: .syncIsFaviconsFetcherEnabled, defaultValue: false).wrappedValue {
Expand All @@ -66,7 +66,7 @@ final class SyncBookmarksAdapter {
database: CoreDataDatabase,
bookmarkManager: BookmarkManager = LocalBookmarkManager.shared,
appearancePreferences: AppearancePreferences = .shared,
syncAdapterErrorHandler: SyncAdapterErrorHandling
syncAdapterErrorHandler: SyncErrorHandling
) {
self.database = database
self.bookmarkManager = bookmarkManager
Expand Down
4 changes: 2 additions & 2 deletions DuckDuckGo/Sync/SyncCredentialsAdapter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@ final class SyncCredentialsAdapter {

private(set) var provider: CredentialsProvider?
let databaseCleaner: CredentialsDatabaseCleaner
let syncAdapterErrorHandler: SyncAdapterErrorHandling
let syncAdapterErrorHandler: SyncErrorHandling
let syncDidCompletePublisher: AnyPublisher<Void, Never>

init(secureVaultFactory: AutofillVaultFactory = AutofillSecureVaultFactory,
syncAdapterErrorHandler: SyncAdapterErrorHandling) {
syncAdapterErrorHandler: SyncErrorHandling) {
syncDidCompletePublisher = syncDidCompleteSubject.eraseToAnyPublisher()
self.syncAdapterErrorHandler = syncAdapterErrorHandler
databaseCleaner = CredentialsDatabaseCleaner(
Expand Down
6 changes: 3 additions & 3 deletions DuckDuckGo/Sync/SyncErrorHandler.swift
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ import PixelKit
import Persistence
import Combine

/// The SyncAdapterErrorHandling protocol defines methods for handling sync errors related to specific data types such as bookmarks and credentials.
protocol SyncAdapterErrorHandling {
/// The SyncErrorHandling protocol defines methods for handling sync errors related to specific data types such as bookmarks and credentials.
protocol SyncErrorHandling {
func handleBookmarkError(_ error: Error)
func handleCredentialError(_ error: Error)
func syncBookmarksSucceded()
Expand Down Expand Up @@ -165,7 +165,7 @@ public class SyncErrorHandler: EventMapping<SyncError>, ObservableObject {
}
}

extension SyncErrorHandler: SyncAdapterErrorHandling {
extension SyncErrorHandler: SyncErrorHandling {
func syncCredentialsSucceded() {
lastSyncSuccessTime = Date()
resetCredentialsErrors()
Expand Down
2 changes: 1 addition & 1 deletion UnitTests/Sync/SyncCredentialsAdapterTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ final class SyncCredentialsAdapterTests: XCTestCase {

}

class CapturingAdapterErrorHandler: SyncAdapterErrorHandling {
class CapturingAdapterErrorHandler: SyncErrorHandling {
var handleBookmarkErrorCalled = false
var syncCredentialsSuccededCalled = false
var handleCredentialErrorCalled = false
Expand Down

0 comments on commit 29b988a

Please sign in to comment.