fix: showing multiple download options

This commit is contained in:
Chubby Granny Chaser 2024-08-18 01:39:50 +01:00
parent c218070463
commit 42ea35441c
No known key found for this signature in database
17 changed files with 118 additions and 98 deletions

View file

@ -8,11 +8,18 @@ export class RepacksManager {
private static repacksIndex = new flexSearch.Index();
public static async updateRepacks() {
this.repacks = await repackRepository.find({
order: {
createdAt: "DESC",
},
});
this.repacks = await repackRepository
.find({
order: {
createdAt: "DESC",
},
})
.then((repacks) =>
repacks.map((repack) => ({
...repack,
uris: JSON.parse(repack.uris),
}))
);
for (let i = 0; i < this.repacks.length; i++) {
this.repacksIndex.remove(i);