Customer avatar validation (#732)

* Customer avatar validation

https://huntr.dev/bounties/19f3e5f7-b419-44b1-9c37-7e4404cbec94/

* Customer avatar validation test

https://huntr.dev/bounties/19f3e5f7-b419-44b1-9c37-7e4404cbec94/
This commit is contained in:
theWorstComrade
2022-01-19 12:38:34 +01:00
committed by GitHub
parent 323b7d8ea6
commit ff3cd0f7b9
2 changed files with 12 additions and 0 deletions

View File

@ -92,6 +92,12 @@ class CustomerProfileRequest extends FormRequest
],
'shipping.fax' => [
'nullable',
],
'customer_avatar' => [
'nullable',
'file',
'mimes:gif,jpg,png',
'max:20000'
]
];
}

View File

@ -73,6 +73,12 @@ test('customer profile request validation rules', function () {
],
'shipping.fax' => [
'nullable',
],
'customer_avatar' => [
'nullable',
'file',
'mimes:gif,jpg,png',
'max:20000'
]
],
$request->rules()