1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-04 15:02:09 +03:00
Files
node-redis/packages/client/lib/commands/AUTH.ts
2021-12-20 14:47:51 -05:00

17 lines
441 B
TypeScript

import { RedisCommandArgument, RedisCommandArguments } from '.';
export interface AuthOptions {
username?: RedisCommandArgument;
password: RedisCommandArgument;
}
export function transformArguments({ username, password }: AuthOptions): RedisCommandArguments {
if (!username) {
return ['AUTH', password];
}
return ['AUTH', username, password];
}
export declare function transformReply(): RedisCommandArgument;