MCPcopy Create free account
hub / github.com/evolution-foundation/evolution-api / hGet

Method hGet

src/api/services/cache.service.ts:23–39  ·  view source on GitHub ↗
(key: string, field: string)

Source from the content-addressed store, hash-verified

21 }
22
23 public async hGet(key: string, field: string) {
24 if (!this.cache) {
25 return null;
26 }
27 try {
28 const data = await this.cache.hGet(key, field);
29
30 if (data) {
31 return JSON.parse(data, BufferJSON.reviver);
32 }
33
34 return null;
35 } catch (error) {
36 this.logger.error(error);
37 return null;
38 }
39 }
40
41 async set(key: string, value: any, ttl?: number) {
42 if (!this.cache) {

Callers

nothing calls this directly

Calls 2

errorMethod · 0.80
hGetMethod · 0.65

Tested by

no test coverage detected