MCPcopy Create free account
hub / github.com/alexankitty/Myrient-Search-Engine / updateMetadata

Function updateMetadata

server.js:118–133  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

116}
117
118async function updateMetadata() {
119 if (updatingFiles) return;
120 let updateMatches = process.env.FORCE_METADATA_RESYNC == "1" ? true : false;
121 if ((await Metadata.count()) < (await metadataManager.getIGDBGamesCount())) {
122 await metadataManager.syncAllMetadata();
123 updateMatches = true;
124 }
125 if (updateMatches) {
126 if (await Metadata.count()) {
127 await metadataManager.matchAllMetadata();
128 }
129 metadataMatchCount = await File.count({
130 where: { detailsId: { [Op.ne]: null } },
131 });
132 }
133}
134
135async function updateKws() {
136 if (updatingFiles) return;

Callers 1

server.jsFile · 0.85

Calls 3

getIGDBGamesCountMethod · 0.80
syncAllMetadataMethod · 0.80
matchAllMetadataMethod · 0.80

Tested by

no test coverage detected