Merge branch 'master' of https://github.com/sebathefox/skolehjem-webapp
This commit is contained in:
commit
3cfcd980f4
|
@ -211,8 +211,17 @@ class UserController extends Controller
|
|||
return Response::detect('users.forgot');
|
||||
}
|
||||
|
||||
public function forgot(){
|
||||
public function forgot(Request $request){
|
||||
$user = User::query()->where('email', '=', $request->email)->first();
|
||||
|
||||
if($user == null){
|
||||
return redirect()->back();
|
||||
}
|
||||
|
||||
//Send email
|
||||
//TODO: Implement mail.
|
||||
|
||||
return redirect()->route('users.login');
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue