diff --git a/Sources/StructuredWebSocketClient/JSONMessageRegistry/JSONMessageName.swift b/Sources/StructuredWebSocketClient/JSONMessageRegistry/JSONMessageName.swift index eb0a7bc..7f489be 100644 --- a/Sources/StructuredWebSocketClient/JSONMessageRegistry/JSONMessageName.swift +++ b/Sources/StructuredWebSocketClient/JSONMessageRegistry/JSONMessageName.swift @@ -30,7 +30,7 @@ public struct JSONMessageName: Sendable, Codable, Equatable, Hashable { public static func initializer( for value: String, ofType: M.Type - ) -> (@escaping @Sendable (M) async -> Void) -> Self { + ) -> @Sendable (@escaping @Sendable (M) async -> Void) -> Self { { handler in .init(value, associatedType: M.self, typeHandler: handler) } }