Updated the permissions to be admin instead of owner
This commit is contained in:
@@ -34,7 +34,7 @@ async function get(req: NextApiRequest, res: NextApiResponse) {
|
||||
}
|
||||
|
||||
async function post(req: NextApiRequest, res: NextApiResponse) {
|
||||
if (!["developer", "owner"].includes(req.session.user!.type))
|
||||
if (!["developer", "admin"].includes(req.session.user!.type))
|
||||
return res.status(403).json({ok: false, reason: "You do not have permission to create a new package"});
|
||||
|
||||
const body = req.body as Package;
|
||||
|
||||
Reference in New Issue
Block a user