From c369ea57031f4879e8223bda8ba86891ae6a09fd Mon Sep 17 00:00:00 2001 From: Andy Heathershaw Date: Wed, 12 Sep 2018 21:24:15 +0100 Subject: [PATCH] =?UTF-8?q?Added=20validation=20to=20the=20user=E2=80=99s?= =?UTF-8?q?=20profile=20alias=20field?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Http/Requests/SaveUserSettingsRequest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Http/Requests/SaveUserSettingsRequest.php b/app/Http/Requests/SaveUserSettingsRequest.php index 0c664f2..4797455 100644 --- a/app/Http/Requests/SaveUserSettingsRequest.php +++ b/app/Http/Requests/SaveUserSettingsRequest.php @@ -26,8 +26,8 @@ class SaveUserSettingsRequest extends FormRequest { return [ 'name' => 'required|max:255', - 'email' => 'required|email|max:255|unique:users,email,' . Auth::user()->id - // TODO include user profile alias + 'email' => 'required|email|max:255|unique:users,email,' . Auth::user()->id, + 'profile_alias' => 'sometimes|max:255|unique:users,profile_alias,' . Auth::user()->id ]; } } \ No newline at end of file