register step

This commit is contained in:
Kevin Adametz 2020-03-26 09:46:06 +01:00
parent 1ada368ed4
commit f06d2d15a5
50 changed files with 748 additions and 276 deletions

View file

@ -76,15 +76,7 @@ class RegisterController extends Controller
$data = Input::all();
$user = $this->userRepo->create($data);
$unique = false;
do{
$confirmation_code = str_random(30);
if(User::where('confirmation_code', '=', $confirmation_code)->count() == 0){
$unique = true;
}
}
while(!$unique);
$confirmation_code = UserService::createConfirmationCode();
$user->lang = !empty(\App::getLocale()) ? \App::getLocale() : "de";
$user->confirmation_code = $confirmation_code;