fix next prev ids

This commit is contained in:
Simon 2025-05-05 22:08:26 +02:00
parent cd65934c8a
commit 9ff5506607

View File

@ -179,8 +179,8 @@ const articlesIdMax = 87;
const articles: ArticleInfo[] = [];
for (let id = articlesIdMin; id <= articlesIdMax; ++id) {
const prevId = id > articlesIdMin ? id : undefined;
const nextId = id < articlesIdMax ? id : undefined;
const prevId = id > articlesIdMin ? id - 1 : undefined;
const nextId = id < articlesIdMax ? id + 2 : undefined;
console.log(`Downloading article ${id}...`);
const article = await downloadArticle(id);