mirror of
https://github.com/imputnet/cobalt.git
synced 2026-10-24 02:52:18 +00:00
Merge 0ff9e49d00 into a636575b09
This commit is contained in:
commit
2e120d1c4e
1 changed files with 8 additions and 5 deletions
|
|
@ -26,11 +26,14 @@ export default class RedisStore extends Store {
|
|||
async _get(key) {
|
||||
await this.#connected;
|
||||
|
||||
const valueType = await this.#client.get(this.#keyOf(key) + '_t');
|
||||
const value = await this.#client.get(
|
||||
commandOptions({ returnBuffers: true }),
|
||||
this.#keyOf(key)
|
||||
);
|
||||
const redisKey = this.#keyOf(key);
|
||||
const [valueType, value] = await Promise.all([
|
||||
this.#client.get(redisKey + '_t'),
|
||||
this.#client.get(
|
||||
commandOptions({ returnBuffers: true }),
|
||||
redisKey
|
||||
)
|
||||
]);
|
||||
|
||||
if (!value) {
|
||||
return null;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue