I have an auth login page which logs in and redirects to home.blade.php
I need here to check whether user_type in user table is admin or Normal. If user_type=='admin' redirect to home else redirect to home_user page.
Route.php
Route::get('/home', 'HomeController@index')->name('home');
Route::get('/home_user', 'HomeController@index')->name('home_user');
or
protected function redirectTo() {
if (Auth::user()->user_type == 'admin')
return '/home';
else
return '/home_user';
}