Skip to content

Commit d8cd550

Browse files
committed
Fix initializers not being public
1 parent 473b395 commit d8cd550

File tree

3 files changed

+9
-0
lines changed

3 files changed

+9
-0
lines changed

Sources/NIORedis/ChannelHandlers/RESPDecoder.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@ public final class RESPDecoder {
3737
case parsed(RESPValue)
3838
}
3939

40+
public init() { }
41+
4042
/// Attempts to parse the `ByteBuffer`, starting at the specified position, following the RESP specification.
4143
///
4244
/// See https://redis.io/topics/protocol

Sources/NIORedis/ChannelHandlers/RESPEncoder.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ import NIO
55
///
66
/// See: https://redis.io/topics/protocol
77
public final class RESPEncoder {
8+
public init() { }
9+
810
/// Encodes the `RedisValue` to bytes, following the RESP specification.
911
///
1012
/// See https://redis.io/topics/protocol

Sources/NIORedis/ChannelHandlers/RedisCommandHandler.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ public struct RedisCommandContext {
77
public let command: RESPValue
88
/// A promise expected to be fulfilled with the `RESPValue` response to the command from Redis.
99
public let promise: EventLoopPromise<RESPValue>
10+
11+
public init(command: RESPValue, promise: EventLoopPromise<RESPValue>) {
12+
self.command = command
13+
self.promise = promise
14+
}
1015
}
1116

1217
/// A `ChannelDuplexHandler` that works with `RedisCommandContext`s to send commands and forward responses.

0 commit comments

Comments
 (0)