Skip to content

Commit 7b9a349

Browse files
committed
Rename RedisCommandContext.promise to responsePromise
1 parent fff2486 commit 7b9a349

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Sources/NIORedis/ChannelHandlers/RedisCommandHandler.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ public struct RedisCommandContext {
66
/// A full command keyword and arguments stored as a single `RESPValue`.
77
public let command: RESPValue
88
/// A promise expected to be fulfilled with the `RESPValue` response to the command from Redis.
9-
public let promise: EventLoopPromise<RESPValue>
9+
public let responsePromise: EventLoopPromise<RESPValue>
1010

1111
public init(command: RESPValue, promise: EventLoopPromise<RESPValue>) {
1212
self.command = command
13-
self.promise = promise
13+
self.responsePromise = promise
1414
}
1515
}
1616

@@ -77,7 +77,7 @@ extension RedisCommandHandler: ChannelOutboundHandler {
7777
/// See `ChannelOutboundHandler.write(ctx:data:promise:)`
7878
public func write(ctx: ChannelHandlerContext, data: NIOAny, promise: EventLoopPromise<Void>?) {
7979
let context = unwrapOutboundIn(data)
80-
commandResponseQueue.insert(context.promise, at: 0)
80+
commandResponseQueue.insert(context.responsePromise, at: 0)
8181
ctx.write(wrapOutboundOut(context.command), promise: promise)
8282
}
8383
}

0 commit comments

Comments
 (0)