MCPcopy Create free account
hub / github.com/subquery/subql / get

Method get

packages/node-core/src/utils/blockHeightMap.ts:24–32  ·  view source on GitHub ↗
(height: number)

Source from the content-addressed store, hash-verified

22 }
23
24 get(height: number): T {
25 const details = this.getDetails(height);
26
27 if (details === undefined) {
28 throw new EntryNotFoundError(height);
29 }
30
31 return details.value;
32 }
33
34 // Same as get but wont throw when there is nothing in the block range
35 getSafe(height: number): T | undefined {

Callers 1

getSafeMethod · 0.95

Calls 1

getDetailsMethod · 0.95

Tested by

no test coverage detected