From 8be90f42a591bfb7650c4f9f041eb4295c23f795 Mon Sep 17 00:00:00 2001 From: Lewis Dale Date: Wed, 27 Sep 2023 07:34:19 +0100 Subject: [PATCH] Put those posts back where they came from or so help me --- src/_data/posts.js | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/_data/posts.js b/src/_data/posts.js index 72f7871..f3643c6 100644 --- a/src/_data/posts.js +++ b/src/_data/posts.js @@ -100,12 +100,8 @@ const mapComment = comment => ({ module.exports = async () => { - // const cache = new PostCache(); - // await cache.fetchLatest(); - - const cache = { - posts: [] - } + const cache = new PostCache(); + await cache.fetchLatest(); return Object.values(cache.posts) .sort(dateSort) @@ -122,4 +118,4 @@ module.exports = async () => { return comments; }, { like: [], reply: [], repost: [] }) })); -}; \ No newline at end of file +};