mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-05-22 07:40:58 +00:00
Set a fairly sensible limit on user name validation
Also updated controller properties with types within modified files. Related to #3614
This commit is contained in:
parent
89ec9a5081
commit
4209f27f1a
3 changed files with 10 additions and 10 deletions
app/Http/Controllers/Api
|
@ -36,7 +36,7 @@ class UserApiController extends ApiController
|
|||
{
|
||||
return [
|
||||
'create' => [
|
||||
'name' => ['required', 'min:2'],
|
||||
'name' => ['required', 'min:2', 'max:100'],
|
||||
'email' => [
|
||||
'required', 'min:2', 'email', new Unique('users', 'email'),
|
||||
],
|
||||
|
@ -48,7 +48,7 @@ class UserApiController extends ApiController
|
|||
'send_invite' => ['boolean'],
|
||||
],
|
||||
'update' => [
|
||||
'name' => ['min:2'],
|
||||
'name' => ['min:2', 'max:100'],
|
||||
'email' => [
|
||||
'min:2',
|
||||
'email',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue