Skip to content

Commit 35a3f20

Browse files
Merge pull request #9 from tkhq/fix/missing-return
Fix missing return statement in guard statement
2 parents 70d94c6 + 6667926 commit 35a3f20

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ The TurnkeySDK is built to support macOS, iOS, tvOS, watchOS, and visionOS, maki
1111
To integrate the TurnkeySDK into your Swift project, you need to add it as a dependency in your Package.swift file:
1212

1313
```swift
14-
.package(url: "https://github.com/tkhq/swift-sdk", from: "1.2.0")
14+
.package(url: "https://github.com/tkhq/swift-sdk", from: "1.2.1")
1515
```
1616

1717
## Usage

Sources/Shared/Stamper.swift

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,10 +117,14 @@ public class Stamper {
117117
}
118118
}
119119

120-
guard let challenge = payload.compactMap { String(format: "%02x", $0) }.joined().data(using: .utf8) else {
120+
guard
121+
let challenge = payload.compactMap({ String(format: "%02x", $0) }).joined().data(
122+
using: .utf8)
123+
else {
121124
continuation.resume(throwing: StampError.assertionFailed)
125+
return
122126
}
123-
127+
124128
self.passkeyManager?.assertPasskey(challenge: challenge)
125129
}
126130
}

0 commit comments

Comments
 (0)