mirror of
https://github.com/strapi/strapi.git
synced 2025-11-01 18:33:55 +00:00
Use same error format
This commit is contained in:
parent
c1329f2284
commit
d598cfaf71
@ -283,7 +283,7 @@ module.exports = {
|
||||
null,
|
||||
formatError({
|
||||
id: 'Auth.form.error.email.format',
|
||||
message: 'Please provide valid email address.',
|
||||
message: 'Please provide a valid email address.',
|
||||
})
|
||||
);
|
||||
}
|
||||
@ -312,7 +312,13 @@ module.exports = {
|
||||
|
||||
// User blocked
|
||||
if (user.blocked) {
|
||||
return ctx.badRequest('blocked.user');
|
||||
return ctx.badRequest(
|
||||
null,
|
||||
formatError({
|
||||
id: 'Auth.form.error.user.blocked',
|
||||
message: 'This user is disabled.',
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
// Generate random token.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user