Skip to content

Commit

Permalink
Refactor EudiWallet.swift to handle pending issuance outcome
Browse files Browse the repository at this point in the history
  • Loading branch information
phisakel committed Oct 13, 2024
1 parent 8fc8121 commit cfe3275
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/EudiWalletKit/EudiWallet.swift
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ public final class EudiWallet: ObservableObject, @unchecked Sendable {
let issueReq = try IssueRequest(id: pendingDoc.id, docType: pendingDoc.docType, privateKeyType: pkt, keyData: pk)
try await openId4VCIService.initSecurityKeys(pendingDoc.privateKeyType == .secureEnclaveP256)
let outcome = try await openId4VCIService.resumePendingIssuance(pendingDoc: pendingDoc, webUrl: webUrl)
guard case .issued(_, _) = outcome else { return pendingDoc }
if case let .pending(_) = outcome { return pendingDoc }
let res = try await finalizeIssuing(id: pendingDoc.id, data: outcome, docType: pendingDoc.docType, format: format, issueReq: issueReq, openId4VCIService: openId4VCIService)
return res
}
Expand Down

0 comments on commit cfe3275

Please sign in to comment.