Skip to content

Commit bd693d5

Browse files
committed
fix linter warnings
1 parent 29e2877 commit bd693d5

13 files changed

+12
-21
lines changed

Sources/WebAuthn/Authenticator.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,4 @@
1515
public struct Authenticator {
1616
let aaguid: [UInt8]
1717
let signCount: UInt32
18-
}
18+
}

Sources/WebAuthn/Authenticator/AttestationObject/AuthenticatorData.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,4 @@ struct AuthenticatorData {
3434
/// For attestation signatures this value will be set. For assertion signatures not.
3535
let attestedData: AttestedCredentialData?
3636
let extData: [UInt8]?
37-
}
37+
}

Sources/WebAuthn/Authenticator/AuthenticatorAttestationResponse.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,4 +140,4 @@ struct ParsedAuthenticatorAttestationResponse {
140140

141141
return (data, length)
142142
}
143-
}
143+
}

Sources/WebAuthn/COSE/COSEKeyType.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,4 @@ enum COSEKeyType: UInt64, RawRepresentable, Codable {
2222
case ellipticKey = 2
2323
/// RSAKey is an RSA Public Key
2424
case rsaKey = 3
25-
}
25+
}

Sources/WebAuthn/Ceremonies/Registration/CredentialCreationResponse.swift

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,4 @@ public struct CredentialCreationResponse: Codable {
3131
case clientExtensionResults
3232
case attestationResponse = "response"
3333
}
34-
}
35-
36-
public struct ClientExtensionResults: Codable {
37-
let wrapped: [String: Any]
38-
39-
public init(from decoder: Decoder) throws {
40-
var container = try decoder.unkeyedContainer()
41-
42-
container.decode([String: Decodable].self)
43-
}
4434
}

Sources/WebAuthn/CeremonyType.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,4 @@
1515
enum CeremonyType: String, Codable {
1616
case create = "webauthn.create"
1717
case assert = "webauthn.get"
18-
}
18+
}

Sources/WebAuthn/CredentialPublicKey.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ struct CredentialPublicKey {
5353
self.algorithm = algorithm
5454
}
5555

56-
func verify(supportedPublicKeyAlgorithms: [PublicKeyCredentialParameters]) throws {
56+
func verify(supportedPublicKeyAlgorithms: [PublicKeyCredentialParameters]) throws {
5757
// Step 17.
5858
guard supportedPublicKeyAlgorithms.map(\.algorithm).contains(algorithm) else {
5959
throw WebAuthnError.unsupportedCredentialPublicKeyAlgorithm

Sources/WebAuthn/Helpers/Base64Utilities.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,4 +50,4 @@ extension String {
5050
}
5151
return Data(base64Encoded: result)
5252
}
53-
}
53+
}

Sources/WebAuthn/Helpers/Numbers+Bytes.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ protocol IntegerTransform: Sequence where Element: FixedWidthInteger {
2424

2525
extension IntegerTransform {
2626
func toInteger<I: FixedWidthInteger>(endian: Endian) -> I {
27+
// swiftlint:disable:next identifier_name
2728
let f = { (accum: I, next: Element) in accum &<< next.bitWidth | I(next) }
2829
return endian == .big ? reduce(0, f) : reversed().reduce(0, f)
2930
}

Sources/WebAuthn/SessionData.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@ public struct SessionData {
2424
self.challenge = challenge
2525
self.userID = userID
2626
}
27-
}
27+
}

0 commit comments

Comments
 (0)