mirror of
https://github.com/Drop-OSS/drop.git
synced 2026-07-25 17:24:48 +10:00
fix: missing metadata preventing game import
when a metadata provider fails to import a game's developer / publisher, the import is no longer blocked. the imports usally fail because there isn't a page for these compaines
This commit is contained in:
@@ -334,10 +334,16 @@ export class IGDBProvider implements MetadataProvider {
|
||||
for (const company of findCompanyResponse) {
|
||||
// if company was a dev or publisher
|
||||
// CANNOT use else since a company can be both
|
||||
if (foundInvolved.developer)
|
||||
developers.push(await developer(company.name));
|
||||
if (foundInvolved.publisher)
|
||||
publishers.push(await publisher(company.name));
|
||||
if (foundInvolved.developer) {
|
||||
const res = await developer(company.name);
|
||||
if (res === undefined) continue;
|
||||
developers.push(res);
|
||||
}
|
||||
if (foundInvolved.publisher) {
|
||||
const res = await publisher(company.name);
|
||||
if (res === undefined) continue;
|
||||
publishers.push(res);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -403,7 +409,7 @@ export class IGDBProvider implements MetadataProvider {
|
||||
return metadata;
|
||||
}
|
||||
|
||||
throw new Error("No results found");
|
||||
throw new Error(`igdb failed to find publisher/developer ${query}`);
|
||||
}
|
||||
async fetchDeveloper(
|
||||
params: _FetchDeveloperMetadataParams,
|
||||
|
||||
Reference in New Issue
Block a user