fix compilation

This commit is contained in:
Michele Balistreri 2024-09-19 10:09:05 +02:00
parent fe748a8dcd
commit f2d5c2ca53
No known key found for this signature in database
GPG Key ID: E9567DA33A4F791A
1 changed files with 5 additions and 5 deletions

View File

@ -113,7 +113,7 @@ class SmartCard {
try cmdSet.installKeycardInstance().checkOK()
os_log("Keycard applet instance re-installed")
factoryResetPost(channel, resolve, reject)
factoryResetPost(channel: channel, resolve: resolve, reject: reject)
}
func factoryReset(channel: CardChannel, resolve: RCTPromiseResolveBlock, reject: RCTPromiseRejectBlock) throws -> Void {
@ -121,24 +121,24 @@ class SmartCard {
var resp = try cmdSet.select()
if (resp.sw != 0x9000) {
factoryResetFallback(channel, resolve, reject)
factoryResetFallback(channel: channel, resolve: resolve, reject: reject)
return
}
let info = try ApplicationInfo(resp.data)
if (!info.hasFactoryResetCapability) {
factoryResetFallback(channel, resolve, reject)
factoryResetFallback(channel: channel, resolve: resolve, reject: reject)
return
}
resp = try cmdSet.factoryReset()
if (resp.sw != 0x9000) {
factoryResetFallback(channel, resolve, reject)
factoryResetFallback(channel: channel, resolve: resolve, reject: reject)
return
}
factoryResetPost(channel, resolve, reject)
factoryResetPost(channel: channel, resolve: resolve, reject: reject)
}
func verifyCard(channel: CardChannel, challenge: String, resolve: RCTPromiseResolveBlock, reject: RCTPromiseRejectBlock) throws {