We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6e5f4f7 commit 17059fdCopy full SHA for 17059fd
src/utils/redis.ts
@@ -104,9 +104,10 @@ if (config.redis?.enabled) {
104
const createKeyName = (key: RedisCommandArgument) => (key + (config.redis.useCompression ? ".c" : "")) as RedisCommandArgument;
105
106
exportClient.getWithCache = (key) => {
107
- if (cache && cacheClient && cache.has(key)) {
+ const cachedItem = cache && cacheClient && cache.get(key);
108
+ if (cachedItem != null) {
109
memoryCacheHits++;
- return Promise.resolve(cache.get(key));
110
+ return Promise.resolve(cachedItem);
111
} else if (shouldClientCacheKey(key)) {
112
memoryCacheMisses++;
113
}
0 commit comments