You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-07 13:22:56 +03:00
fix multi "generic" type, some docs
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import { CommandArguments, RedisScript, TransformReply } from './RESP/types';
|
||||
import { CommandArguments, RedisScript, ReplyUnion, TransformReply } from './RESP/types';
|
||||
|
||||
// TODO: enum?
|
||||
export type MULTI_REPLY = {
|
||||
GENERIC: 'generic';
|
||||
TYPED: 'typed';
|
||||
@@ -8,7 +7,7 @@ export type MULTI_REPLY = {
|
||||
|
||||
export type MultiReply = MULTI_REPLY[keyof MULTI_REPLY];
|
||||
|
||||
export type MultiReplyType<T extends MultiReply, REPLIES> = T extends MULTI_REPLY['TYPED'] ? REPLIES : Array<unknown>;
|
||||
export type MultiReplyType<T extends MultiReply, REPLIES> = T extends MULTI_REPLY['TYPED'] ? REPLIES : Array<ReplyUnion>;
|
||||
|
||||
export interface RedisMultiQueuedCommand {
|
||||
args: CommandArguments;
|
||||
|
Reference in New Issue
Block a user