1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-09 00:22:08 +03:00
Files
node-redis/lib/commands/RPUSH.ts

21 lines
443 B
TypeScript

import { transformReplyNumber } from './generic-transformers';
export const FIRST_KEY_INDEX = 1;
export function transformArguments(key: string, element: string | Array<string>): Array<string> {
const args = [
'RPUSH',
key
];
if (typeof element === 'string') {
args.push(element);
} else {
args.push(...element);
}
return args;
}
export const transformReply = transformReplyNumber;