MCPcopy Index your code
hub / github.com/Ptechgithub/pp-worker / getApiResponse

Function getApiResponse

_worker.js:300–305  ·  view source on GitHub ↗

* Returns the cached API response if it exists, otherwise fetches the API response from the server and caches it for future use. * @returns {Promise } A Promise that resolves to the cached API response object or the fetched API response object, or null if there was an error.

()

Source from the content-addressed store, hash-verified

298 * @returns {Promise<object|null>} A Promise that resolves to the cached API response object or the fetched API response object, or null if there was an error.
299 */
300async function getApiResponse() {
301 if (!apiResponseCache) {
302 return await fetchApiResponse();
303 }
304 return apiResponseCache;
305}
306
307/**
308 * Checks if a given UUID is present in the API response.

Callers 1

checkUuidInApiResponseFunction · 0.85

Calls 1

fetchApiResponseFunction · 0.85

Tested by

no test coverage detected