Skip to content

Commit

Permalink
Showcase build errors
Browse files Browse the repository at this point in the history
  • Loading branch information
flypaper0 committed Sep 2, 2022
1 parent 8cf76ad commit a9f921b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import Auth

final class WalletInteractor {

func pair(uri: String) async throws {
try await Auth.instance.pair(uri: WalletConnectURI(string: uri)!)
func pair(uri: WalletConnectURI) async throws {
try await Auth.instance.pair(uri: uri)
}

var requestPublisher: AnyPublisher<AuthRequest, Never> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,14 @@ final class WalletPresenter: ObservableObject {
}

func didPastePairingURI() {
guard let uri = UIPasteboard.general.string else { return }
guard let string = UIPasteboard.general.string, let uri = WalletConnectURI(string: string) else { return }
pair(uri: uri)
}

func didScanPairingURI() {
router.presentScan { [unowned self] value in
self.pair(uri: value)
guard let uri = WalletConnectURI(string: value) else { return }
self.pair(uri: uri)
self.router.dismiss()
} onError: { error in
print(error.localizedDescription)
Expand Down Expand Up @@ -53,7 +54,7 @@ private extension WalletPresenter {
}.store(in: &disposeBag)
}

func pair(uri: String) {
func pair(uri: WalletConnectURI) {
Task(priority: .high) { [unowned self] in
try await self.interactor.pair(uri: uri)
}
Expand Down

0 comments on commit a9f921b

Please sign in to comment.