order placement doesnt crash

This commit is contained in:
Tim Olson
2023-10-14 22:06:43 -04:00
parent 7b1ed173d7
commit a0f7b26b5f
3 changed files with 27 additions and 14 deletions

View File

@@ -30,6 +30,10 @@ export class CacheDict {
async get(chain, key) {
return await redis.hGet(`${chain}|${this.series}`, key)
}
async contains(chain, key) {
return await redis.hExists(`${chain}|${this.series}`, key)
}
}
@@ -52,6 +56,6 @@ async function latestBlock(chain) {
return await blockCaches[chain].get()
}
export const vaults = new CacheSet('v')
export const vaults = new CacheDict('v')
export const vaultTokens = new CacheDict('vt')
export const prices = new CacheDict('p')