Skip to content

Commit

Permalink
Add registered method (#16036)
Browse files Browse the repository at this point in the history
call to registered method just like what AuthenticatesUsers Trait does to authenticated.
  • Loading branch information
ekoeryanto authored and taylorotwell committed Oct 21, 2016
1 parent 9adce32 commit dadc762
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion src/Illuminate/Foundation/Auth/RegistersUsers.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ public function register(Request $request)

$this->guard()->login($user);

return redirect($this->redirectPath());
return $this->registered($request, $user)
?: redirect($this->redirectPath());
}

/**
Expand All @@ -46,4 +47,16 @@ protected function guard()
{
return Auth::guard();
}

/**
* The user has been registered.
*
* @param \Illuminate\Http\Request $request
* @param mixed $user
* @return mixed
*/
protected function registered(Request $request, $user)
{
return null;
}
}

0 comments on commit dadc762

Please sign in to comment.