0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-01 17:22:42 +00:00

fixes as asked

This commit is contained in:
Víctor Losada Hernández
2024-12-14 23:34:12 +01:00
parent afc92c4545
commit 99f2972079
3 changed files with 15 additions and 25 deletions

View File

@@ -280,7 +280,6 @@ app.get('/css/:id', asyncHandler(getBrew('share')), (req, res)=>{getCSS(req, res
//User Page
app.get('/user/:username', async (req, res, next)=>{
const ownAccount = req.account && (req.account.username == req.params.username);
console.log(req.account);
req.ogMeta = { ...defaultMetaTags,
title : `${req.params.username}'s Collection`,
@@ -352,7 +351,6 @@ app.get('/user/:username', async (req, res, next)=>{
//Change author name on brews
app.put('/api/user/rename', async (req, res)=>{
console.log(req.account);
const { username, newUsername } = req.body;
console.log(`is user ${req.account.username} equal to ${username}? ${req.account.username === username} ${req.account.username === username && 'then add the damn auth for renaming!'}`);
console.log('renaming');