Skip to content
Snippets Groups Projects
Commit 0498cb31 authored by Dariusz Rybicki's avatar Dariusz Rybicki
Browse files

Add remove function to PasswordStorage

parent dddbc9b2
No related branches found
No related tags found
2 merge requests!102Release 1.0.0,!59Update MessengerDestory
...@@ -8,19 +8,23 @@ public struct PasswordStorage { ...@@ -8,19 +8,23 @@ public struct PasswordStorage {
public init( public init(
save: @escaping (Data) throws -> Void, save: @escaping (Data) throws -> Void,
load: @escaping () throws -> Data load: @escaping () throws -> Data,
remove: @escaping () throws -> Void
) { ) {
self.save = save self.save = save
self.load = load self.load = load
self.remove = remove
} }
public var save: (Data) throws -> Void public var save: (Data) throws -> Void
public var load: () throws -> Data public var load: () throws -> Data
public var remove: () throws -> Void
} }
extension PasswordStorage { extension PasswordStorage {
public static let unimplemented = PasswordStorage( public static let unimplemented = PasswordStorage(
save: XCTUnimplemented("\(Self.self).save"), save: XCTUnimplemented("\(Self.self).save"),
load: XCTUnimplemented("\(Self.self).load") load: XCTUnimplemented("\(Self.self).load"),
remove: XCTUnimplemented("\(Self.self).remove")
) )
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment