Skip to content

Commit

Permalink
Customer avatar validation (#732)
Browse files Browse the repository at this point in the history
  • Loading branch information
theWorstComrade committed Jan 19, 2022
1 parent 323b7d8 commit ff3cd0f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
6 changes: 6 additions & 0 deletions app/Http/Requests/Customer/CustomerProfileRequest.php
Expand Up @@ -92,6 +92,12 @@ public function rules()
],
'shipping.fax' => [
'nullable',
],
'customer_avatar' => [
'nullable',
'file',
'mimes:gif,jpg,png',
'max:20000'
]
];
}
Expand Down
6 changes: 6 additions & 0 deletions tests/Unit/Request/Customer/CustomerProfileTest.php
Expand Up @@ -73,6 +73,12 @@
],
'shipping.fax' => [
'nullable',
],
'customer_avatar' => [
'nullable',
'file',
'mimes:gif,jpg,png',
'max:20000'
]
],
$request->rules()
Expand Down

0 comments on commit ff3cd0f

Please sign in to comment.