You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-09 00:22:08 +03:00
time-series
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
import { RedisArgument, TuplesReply, NumberReply, DoubleReply, Resp2Reply, Command } from '@redis/client/dist/lib/RESP/types';
|
||||
import { pushLatestArgument } from '.';
|
||||
|
||||
export interface TsGetOptions {
|
||||
LATEST?: boolean;
|
||||
@@ -11,7 +10,13 @@ export default {
|
||||
FIRST_KEY_INDEX: 1,
|
||||
IS_READ_ONLY: true,
|
||||
transformArguments(key: RedisArgument, options?: TsGetOptions) {
|
||||
return pushLatestArgument(['TS.GET', key], options?.LATEST);
|
||||
const args = ['TS.GET', key];
|
||||
|
||||
if (options?.LATEST) {
|
||||
args.push('LATEST');
|
||||
}
|
||||
|
||||
return args;
|
||||
},
|
||||
transformReply: {
|
||||
2(reply: Resp2Reply<TsGetReply>) {
|
||||
|
Reference in New Issue
Block a user