MCPcopy Index your code
hub / github.com/wavetermdev/waveterm / getObjectValue

Function getObjectValue

frontend/app/store/wos.ts:290–297  ·  view source on GitHub ↗
(oref: string, getFn?: Getter)

Source from the content-addressed store, hash-verified

288// should provide getFn if it is available (e.g. inside of a jotai atom)
289// otherwise it will use the globalStore.get function
290function getObjectValue<T extends WaveObj>(oref: string, getFn?: Getter): T {
291 const wov = getWaveObjectValue<T>(oref);
292 if (getFn == null) {
293 getFn = globalStore.get;
294 }
295 const atomVal = getFn(wov.dataAtom);
296 return atomVal.value;
297}
298
299// sets the value of a WaveObject in the cache.
300// should provide setFn if it is available (e.g. inside of a jotai atom)

Callers

nothing calls this directly

Calls 1

getWaveObjectValueFunction · 0.85

Tested by

no test coverage detected