diff --git a/app/Http/Requests/SubmitVerificationCode.php b/app/Http/Requests/SubmitVerificationCode.php index 0d77da7..26202c9 100644 --- a/app/Http/Requests/SubmitVerificationCode.php +++ b/app/Http/Requests/SubmitVerificationCode.php @@ -2,12 +2,12 @@ namespace App\Http\Requests; -//use App\Traits\CharacterCommon; +use App\Traits\CharacterCommon; use Illuminate\Foundation\Http\FormRequest; class SubmitVerificationCode extends FormRequest { -// use CharacterCommon; + use CharacterCommon; public function authorize() { @@ -23,17 +23,17 @@ public function rules() public function prepareForValidation() { -// $this->replaceNumbers(); + $this->replaceNumbers(); parent::prepareForValidation(); } -// protected function replaceNumbers() -// { -// $input = $this->request->all(); -// if (isset($input["code"])) { -// $input["code"] = preg_replace('/\s+/', '', $input["code"]); -// $input["code"] = $this->convertToEnglish($input["code"]); -// } -// $this->replace($input); -// } + protected function replaceNumbers() + { + $input = $this->request->all(); + if (isset($input["code"])) { + $input["code"] = preg_replace('/\s+/', '', $input["code"]); + $input["code"] = $this->convertToEnglish($input["code"]); + } + $this->replace($input); + } }