0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2025-12-28 02:42:39 +00:00
Fix admin added as author #3952
This commit is contained in:
Trevor Buckner
2024-12-18 23:22:06 -05:00
committed by GitHub

View File

@@ -1,5 +1,5 @@
import {model as HomebrewModel } from './homebrew.model.js';
import {model as NotificationModel } from './notifications.model.js';
import { model as HomebrewModel } from './homebrew.model.js';
import { model as NotificationModel } from './notifications.model.js';
import express from 'express';
import Moment from 'moment';
import zlib from 'zlib';
@@ -108,6 +108,9 @@ router.put('/admin/clean/script/:id', asyncHandler(HomebrewAPI.getBrew('admin',
req.body = brew;
// Remove Account from request to prevent Admin user from being added to brew as an Author
req.account = undefined;
return await HomebrewAPI.updateBrew(req, res);
});