🔧 Flattened the array of volumes returned from the recursive search call to CV

This commit is contained in:
2021-12-24 17:09:07 -08:00
parent 71223fb8ed
commit b95a98c41e
2 changed files with 21 additions and 11 deletions

View File

@@ -191,14 +191,13 @@ export default class ComicVineService extends Service {
output.push(...data.results);
// 1a. Run the current batch of volumes through the matcher
// Check for: issue year falling in the range of the volume run
rankVolumes(output, params.scorerConfiguration);
currentPage += 1;
params.page = currentPage;
console.log(`Fetching results for page ${currentPage}...`);
return await this.fetchVolumesFromCV(params, output);
} else {
return output;
return { ...output };
}
},
},