From c1eb19c51c7f152c60f5d97c0c9cdb5cfb189a07 Mon Sep 17 00:00:00 2001 From: franknstayn Date: Mon, 11 Oct 2021 20:07:15 +0800 Subject: [PATCH] enable captcha --- app/Http/Controllers/CustomAuthController.php | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/app/Http/Controllers/CustomAuthController.php b/app/Http/Controllers/CustomAuthController.php index 7310717..3408531 100755 --- a/app/Http/Controllers/CustomAuthController.php +++ b/app/Http/Controllers/CustomAuthController.php @@ -78,23 +78,23 @@ class CustomAuthController extends Controller $post['captcha'] = $this->captchaCheck(); $validator = Validator::make( - // $post, - // [ - // 'username' => 'unique:user_logins', - // 'email' => 'unique:user_logins', - // 'g-recaptcha-response' => 'required', - // 'captcha' => 'required|min:1' - // ], - // [ - // 'g-recaptcha-response.required' => 'Captcha is required', - // 'captcha.min' => 'Wrong captcha, please try again.' - // ] - $post, [ 'username' => 'unique:user_logins', 'email' => 'unique:user_logins', + 'g-recaptcha-response' => 'required', + 'captcha' => 'required|min:1' + ], + [ + 'g-recaptcha-response.required' => 'Captcha is required', + 'captcha.min' => 'Wrong captcha, please try again.' ] + + // $post, + // [ + // 'username' => 'unique:user_logins', + // 'email' => 'unique:user_logins', + // ] );