ATOM / JSON feed hotfix

Signed-off-by: Armored Dragon <publicmail@armoreddragon.com>
account-personalization
Armored Dragon 2024-05-02 11:28:35 -05:00
parent 6dde5d7020
commit 0dd6a7fa00
Signed by: ArmoredDragon
GPG Key ID: C7207ACC3382AD8B
2 changed files with 3 additions and 4 deletions

View File

@ -23,7 +23,7 @@ async function getFeed({ type = "rss" }) {
let feed = getBaseFeed();
// Get posts
let posts = await core.getPost(null, null, { limit: 20 });
let posts = await core.getPost(undefined, undefined, { limit: 20 });
// For each post, add a formatted object to the feed
posts.data.forEach((post) => {
@ -45,7 +45,6 @@ async function getFeed({ type = "rss" }) {
feed.addItem(formatted);
});
// if (type === "rss") return feed.rss2();
if (type === "atom") return feed.atom1();
if (type === "json") return feed.json1();
}

View File

@ -1,8 +1,8 @@
<div class="footer">
<div class="page-center">
<div class="resources">
<a class="atom-feed icon" href="#"><span>ATOM Feed</span> </a>
<a class="json icon" href="#"><span>JSON Feed</span></a>
<a class="atom-feed icon" href="/atom"><span>ATOM Feed</span> </a>
<a class="json icon" href="/json"><span>JSON Feed</span></a>
</div>
<div class="info">
<a class="json icon" href="https://github.com/armored-dragon/yet-another-blog">Built using Yet-Another-Blog</a>