mirror of
https://github.com/strapi/strapi.git
synced 2025-11-02 10:55:37 +00:00
Return HTTP 403 if user is not allowed to perform an operation
This commit is contained in:
parent
3056a7f18f
commit
9e897bcfda
@ -39,7 +39,7 @@ module.exports = async (ctx, next) => {
|
||||
}, []);
|
||||
|
||||
if (!permission) {
|
||||
ctx.unauthorized();
|
||||
ctx.forbidden();
|
||||
|
||||
return ctx.request.graphql = ctx.body;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user