(
type: string,
args: string[],
value: any,
expirySeconds: number,
)
| 19 | } |
| 20 | |
| 21 | async set( |
| 22 | type: string, |
| 23 | args: string[], |
| 24 | value: any, |
| 25 | expirySeconds: number, |
| 26 | ): Promise<void> { |
| 27 | const key = this.generateKey(type, args); |
| 28 | if (expirySeconds) { |
| 29 | await this.client.set(key, JSON.stringify(value), 'EX', expirySeconds); |
| 30 | } else { |
| 31 | await this.client.set(key, JSON.stringify(value)); |
| 32 | } |
| 33 | } |
| 34 | |
| 35 | async get(type: string, args: string[]): Promise<any> { |
| 36 | const key = this.generateKey(type, args); |
nothing calls this directly
no test coverage detected