test logging on phone verify

This commit is contained in:
saparatayev 2023-05-06 12:07:45 +05:00
parent e299400e53
commit 6a3a6b6f74
1 changed files with 5 additions and 0 deletions

View File

@ -404,18 +404,23 @@ class Account extends ComponentBase
$result = SMS::send(str_replace(array('+', ' ', '(' , ')', '-'), '', $this->user()->username), $code); $result = SMS::send(str_replace(array('+', ' ', '(' , ')', '-'), '', $this->user()->username), $code);
// $result = 0; // $result = 0;
\Log::info('send sms result');
\Log::info($result);
switch ($result) { switch ($result) {
case 0: case 0:
$this->user()->phone_activation_code = $code; $this->user()->phone_activation_code = $code;
$this->user()->save(); $this->user()->save();
\Log::info('case 0');
break; break;
case 1: case 1:
return \Redirect::to('/error'); return \Redirect::to('/error');
\Log::info('case 1');
break; break;
default: default:
return \Redirect::to('/error'); return \Redirect::to('/error');
\Log::info('case default');
break; break;
} }
} }