fixed the feed

This commit is contained in:
ld3zian 2025-01-28 18:34:35 -07:00
parent 40552e471c
commit 6ca77cf6af
2 changed files with 4 additions and 2 deletions

View file

@ -42,13 +42,14 @@ export const GET: APIRoute = async ({ params, request }) => {
language: lang, language: lang,
copyright: "All rights reserved", copyright: "All rights reserved",
updated: new Date(), updated: new Date(),
generator: 'ComicK RSS Generator',
}); });
chapters.forEach((chapter) => { chapters.forEach((chapter) => {
const chapterUrl = `https://comick.io/comic/${chapter.md_comics.slug}`; const chapterUrl = `https://comick.io/comic/${chapter.md_comics.slug}`;
feed.addItem({ feed.addItem({
title: `${chapter.md_comics.title} - Chapter ${chapter.chap}`, title: `${chapter.md_comics.title} - Chapter ${chapter.chap}`,
id: `urn:comick:${chapter.md_comics.slug}:${chapter.chap}`, id: `${chapter.md_comics.slug}-${chapter.chap}`,
link: chapterUrl, link: chapterUrl,
description: ` description: `
<div> <div>

View file

@ -36,13 +36,14 @@ export const GET: APIRoute = async ({ params, url }) => {
language: lang, language: lang,
copyright: "All rights reserved", copyright: "All rights reserved",
updated: new Date(), updated: new Date(),
generator: 'ComicK RSS Generator',
}); });
chapters.forEach((chapter) => { chapters.forEach((chapter) => {
const chapterUrl = `https://comick.io/comic/${chapter.md_comics.slug}`; const chapterUrl = `https://comick.io/comic/${chapter.md_comics.slug}`;
feed.addItem({ feed.addItem({
title: `${chapter.md_comics.title} - Chapter ${chapter.chap}`, title: `${chapter.md_comics.title} - Chapter ${chapter.chap}`,
id: `urn:comick:${chapter.md_comics.slug}:${chapter.chap}`, id: `${chapter.md_comics.slug}-${chapter.chap}`,
link: chapterUrl, link: chapterUrl,
description: `New chapter available: Chapter ${chapter.chap}`, description: `New chapter available: Chapter ${chapter.chap}`,
date: new Date(chapter.updated_at), date: new Date(chapter.updated_at),