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

Refactor UserDiscoveryPermanentDeleteAccount

parent 8fa17463
No related branches found
No related tags found
2 merge requests!102Release 1.0.0,!42Update Bindings
...@@ -4,15 +4,15 @@ import XCTestDynamicOverlay ...@@ -4,15 +4,15 @@ import XCTestDynamicOverlay
public struct UserDiscoveryPermanentDeleteAccount { public struct UserDiscoveryPermanentDeleteAccount {
public var run: (Fact) throws -> Void public var run: (Fact) throws -> Void
public func callAsFunction(_ fact: Fact) throws { public func callAsFunction(username: Fact) throws {
try run(fact) try run(username)
} }
} }
extension UserDiscoveryPermanentDeleteAccount { extension UserDiscoveryPermanentDeleteAccount {
public static func live(_ bindingsUD: BindingsUserDiscovery) -> UserDiscoveryPermanentDeleteAccount { public static func live(_ bindingsUD: BindingsUserDiscovery) -> UserDiscoveryPermanentDeleteAccount {
UserDiscoveryPermanentDeleteAccount { fact in UserDiscoveryPermanentDeleteAccount { username in
try bindingsUD.permanentDeleteAccount(fact.encode()) try bindingsUD.permanentDeleteAccount(username.encode())
} }
} }
} }
......
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