From 56f4e3b226b89bea0e9914396b1713df85005043 Mon Sep 17 00:00:00 2001 From: unknown Date: Sat, 9 May 2026 08:01:13 -0600 Subject: [PATCH] Increase file upload validation limits - EntregaController: max:2048 -> max:20480 (2MB -> 20MB) - UpdateUserProfileInformation: max:1024 -> max:5120 (1MB -> 5MB) The server-level limits (nginx client_max_body_size and php.ini) were already raised in the previous commit; these Laravel validation rules were the remaining bottleneck blocking uploads over 2MB. Co-Authored-By: Claude Sonnet 4.6 --- app/Actions/Fortify/UpdateUserProfileInformation.php | 2 +- app/Http/Controllers/EntregaController.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Actions/Fortify/UpdateUserProfileInformation.php b/app/Actions/Fortify/UpdateUserProfileInformation.php index 7bd2ea36..9dab5848 100644 --- a/app/Actions/Fortify/UpdateUserProfileInformation.php +++ b/app/Actions/Fortify/UpdateUserProfileInformation.php @@ -22,7 +22,7 @@ class UpdateUserProfileInformation implements UpdatesUserProfileInformation 'apellidoPaterno' => ['nullable', 'string', 'max:255'], 'apellidoMaterno' => ['nullable', 'string', 'max:255'], 'email' => ['required', 'email', 'max:255', Rule::unique('users')->ignore($user->id)], - 'photo' => ['nullable', 'mimes:jpg,jpeg,png', 'max:1024'], + 'photo' => ['nullable', 'mimes:jpg,jpeg,png', 'max:5120'], ])->validateWithBag('updateProfileInformation'); if (isset($input['photo'])) { diff --git a/app/Http/Controllers/EntregaController.php b/app/Http/Controllers/EntregaController.php index e33c1116..6893ed8e 100644 --- a/app/Http/Controllers/EntregaController.php +++ b/app/Http/Controllers/EntregaController.php @@ -71,7 +71,7 @@ class EntregaController extends Controller public function store(Request $request, Tarea $tarea) { $request->validate([ - 'archivo' => 'nullable|file|max:2048', + 'archivo' => 'nullable|file|max:20480', 'texto' => 'nullable|string|max:5000', ]);