MCPcopy Create free account
hub / github.com/OpenSIST/OpenSIST.github.io / getProgramDesc

Function getProgramDesc

src/Data/ProgramData.js:131–140  ·  view source on GitHub ↗
(programId, isRefresh = false, {priority = FOREGROUND_PRIORITY} = {})

Source from the content-addressed store, hash-verified

129export async function getProgramDesc(programId, isRefresh = false, {priority = FOREGROUND_PRIORITY} = {}) {
130 /*
131 * Get the description of the program from the server or local storage by programId
132 * @param programId [String]: programId
133 * @param isRefresh [Boolean]: whether to refresh the data
134 * @return: description of the program
135 */
136 const descriptions = await getProgramDescs([programId], isRefresh, {priority});
137 return descriptions[programId];
138}
139
140export async function getProgramDescs(programIds, isRefresh = false, {priority = FOREGROUND_PRIORITY} = {}) {
141 const uniqueProgramIds = [...new Set(programIds)].filter(Boolean);
142 const requestEpoch = getCacheEpoch();
143 const entries = await Promise.all(uniqueProgramIds.map((programId) => (

Callers 2

actionFunction · 0.90
getProgramContentFunction · 0.85

Calls 1

getProgramDescsFunction · 0.85

Tested by

no test coverage detected