Skip to content

Commit

Permalink
remove unused decompression error
Browse files Browse the repository at this point in the history
  • Loading branch information
MahdiBM committed Jan 11, 2023
1 parent e90c3d7 commit 32b517b
Showing 1 changed file with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ public enum Decompression {

public struct Configuration {
/// `deflate` is the main compression algorithm for web-sockets (RFC 7692),
/// and for now we only support `deflate`.
/// so for now we only support `deflate`.
let algorithm: Compression.Algorithm = .deflate

private init() { }
Expand All @@ -15,17 +15,13 @@ public enum Decompression {
public struct DecompressionError: Error, Equatable, CustomStringConvertible {

private enum Base: Error, Equatable {
case limit
case inflationError(Int)
case initializationError(Int)
case invalidTrailingData
}

private var base: Base

/// The set ``DecompressionLimit`` has been exceeded
public static let limit = Self(base: .limit)

/// An error occurred when inflating. Error code is included to aid diagnosis.
public static var inflationError: (Int) -> Self = {
Self(base: .inflationError($0))
Expand Down

0 comments on commit 32b517b

Please sign in to comment.