From 1bcfb787a6e32585404ded7732532a120cf80c08 Mon Sep 17 00:00:00 2001 From: keyan Date: Mon, 10 Oct 2022 16:58:50 -0500 Subject: [PATCH] add changelog to footer --- api/resolvers/item.js | 2 +- components/footer.js | 20 ++++++++++++++------ next.config.js | 4 ++++ 3 files changed, 19 insertions(+), 7 deletions(-) diff --git a/api/resolvers/item.js b/api/resolvers/item.js index b9cea7fd..b34d6378 100644 --- a/api/resolvers/item.js +++ b/api/resolvers/item.js @@ -986,7 +986,7 @@ export const updateItem = async (parent, { id, data: { title, url, text, boost, // if it's not the FAQ, not their bio, and older than 10 minutes const user = await models.user.findUnique({ where: { id: me.id } }) - if (old.id !== 349 && user.bioId !== id && Date.now() > new Date(old.createdAt).getTime() + 10 * 60000) { + if (![349, 76894, 78763].includes(old.id) && user.bioId !== id && Date.now() > new Date(old.createdAt).getTime() + 10 * 60000) { throw new UserInputError('item can no longer be editted') } diff --git a/components/footer.js b/components/footer.js index 93181183..8bd56a44 100644 --- a/components/footer.js +++ b/components/footer.js @@ -163,6 +163,10 @@ export default function Footer ({ noLinks }) { chat + \ + + rss +
@@ -177,13 +181,17 @@ export default function Footer ({ noLinks }) { \ - - privacy - + + + changes + + \ - - rss - + + + privacy + +
} {data && diff --git a/next.config.js b/next.config.js index e2cd822e..2c9a6179 100644 --- a/next.config.js +++ b/next.config.js @@ -59,6 +59,10 @@ module.exports = withPlausibleProxy()({ source: '/privacy', destination: '/items/76894' }, + { + source: '/changes', + destination: '/items/78763' + }, { source: '/.well-known/lnurlp/:username', destination: '/api/lnurlp/:username'