You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-10 11:43:01 +03:00
15 lines
365 B
TypeScript
15 lines
365 B
TypeScript
import { AuthOptions, transformArguments as transformAuthArguments } from './AUTH';
|
|
|
|
export function transformArguments(protover?: number, auth?: AuthOptions): Array<string> {
|
|
const args = ['HELLO'];
|
|
|
|
if (protover) {
|
|
args.push(protover.toString());
|
|
}
|
|
|
|
if (auth) {
|
|
args.push(...transformAuthArguments(auth));
|
|
}
|
|
|
|
return args;
|
|
} |