Skip to content

Commit a620f57

Browse files
refactor: Remove unused types
1 parent 3937825 commit a620f57

1 file changed

Lines changed: 0 additions & 24 deletions

File tree

Sources/GraphQLTransportWS/GraphqlTransportWSError.swift

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -44,34 +44,13 @@ struct GraphQLTransportWSError: Error {
4444
)
4545
}
4646

47-
static func noType() -> Self {
48-
return self.init(
49-
"Message has no 'type' field",
50-
code: .noType
51-
)
52-
}
53-
5447
static func invalidType() -> Self {
5548
return self.init(
5649
"Message 'type' value does not match supported types",
5750
code: .invalidType
5851
)
5952
}
6053

61-
static func invalidRequestFormat(messageType: RequestMessageType) -> Self {
62-
return self.init(
63-
"Request message doesn't match '\(messageType.rawValue)' JSON format",
64-
code: .invalidRequestFormat
65-
)
66-
}
67-
68-
static func invalidResponseFormat(messageType: ResponseMessageType) -> Self {
69-
return self.init(
70-
"Response message doesn't match '\(messageType.rawValue)' JSON format",
71-
code: .invalidResponseFormat
72-
)
73-
}
74-
7554
static func internalAPIStreamIssue(errors: [GraphQLError]) -> Self {
7655
return self.init(
7756
"API Response did not result in a stream type, contained errors\n \(errors.map { $0.message }.joined(separator: "\n"))",
@@ -98,10 +77,7 @@ public enum ErrorCode: Int, CustomStringConvertible, Sendable {
9877

9978
// Message errors
10079
case invalidEncoding = 4410
101-
case noType = 4411
10280
case invalidType = 4412
103-
case invalidRequestFormat = 4413
104-
case invalidResponseFormat = 4414
10581

10682
// Initialization errors
10783
case unauthorized = 4430

0 commit comments

Comments
 (0)