Skip to content

Instantly share code, notes, and snippets.

@MaheKarim
Created September 29, 2019 15:49
Show Gist options
  • Save MaheKarim/b560b8df18995f908eb385256b88664b to your computer and use it in GitHub Desktop.
Save MaheKarim/b560b8df18995f908eb385256b88664b to your computer and use it in GitHub Desktop.
Disable Auto Login After Registration
// Add This Code To Register Controller
use Illuminate\Http\Request;
use Illuminate\Auth\Events\Registered;
public function register(Request $request)
{
$this->validator($request->all())->validate();
event(new Registered($user = $this->create($request->all())));
return $this->registered($request, $user)
?: redirect($this->redirectPath());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment