fix: Badge=Release-Cache unified, 3er-Batches parallel, COMPLETE.BLURAY filter korrekt
This commit is contained in:
@@ -303,12 +303,13 @@ function KinoGrid({ onOpenModal }) {
|
||||
const moviesMeta = movies.map(m => ({ id: m.id, title: m.title, original_title: m.original_title }));
|
||||
let active = true;
|
||||
(async () => {
|
||||
for (const m of moviesMeta) {
|
||||
for (let bi = 0; bi < moviesMeta.length; bi += 3) {
|
||||
if (!active) break;
|
||||
const chunk = moviesMeta.slice(bi, bi + 3);
|
||||
try {
|
||||
const result = await api('/tools/media/xrel-check', { method:'POST', body:{ movies: [m] } });
|
||||
const result = await api('/tools/media/xrel-check', { method:'POST', body:{ movies: chunk } });
|
||||
if (!active) break;
|
||||
if (result[m.id]) setXrelIds(prev => new Set([...prev, m.id]));
|
||||
chunk.forEach(m => { if (result[m.id]) setXrelIds(prev => new Set([...prev, m.id])); });
|
||||
} catch (_) {}
|
||||
}
|
||||
})();
|
||||
@@ -371,12 +372,13 @@ function DemnächstGrid({ onOpenModal }) {
|
||||
const moviesMeta = allMovies.map(m => ({ id: m.id, title: m.title, original_title: m.original_title }));
|
||||
let active = true;
|
||||
(async () => {
|
||||
for (const m of moviesMeta) {
|
||||
for (let bi = 0; bi < moviesMeta.length; bi += 3) {
|
||||
if (!active) break;
|
||||
const chunk = moviesMeta.slice(bi, bi + 3);
|
||||
try {
|
||||
const result = await api('/tools/media/xrel-check', { method:'POST', body:{ movies: [m] } });
|
||||
const result = await api('/tools/media/xrel-check', { method:'POST', body:{ movies: chunk } });
|
||||
if (!active) break;
|
||||
if (result[m.id]) setXrelIds(prev => new Set([...prev, m.id]));
|
||||
chunk.forEach(m => { if (result[m.id]) setXrelIds(prev => new Set([...prev, m.id])); });
|
||||
} catch (_) {}
|
||||
}
|
||||
})();
|
||||
|
||||
Reference in New Issue
Block a user