laravel - how to retrive status value from $user? -


protected function authenticated(request $request, $user)     {         //         $user = user::findorfail($user);         return $user;         //$arruser = $user->toarray();       /*  if($user->status==0){           auth::logout();           return redirect('login')->with('verify_info','verify first');         }*/     } 

$user returning---> id 54 name "rasul" email "golam.rasul@gmail.com" verify_token "biof8l8djb" status 0 created_at "2017-07-26 09:39:46" updated_at "2017-07-26 09:39:46" problem when m trying value of status using $user-> status says property [status] not exist on collection instance.

when return $user collection how object first() , property status.

something :

    $user = user::findorfail($user)->first();     return $user; 

Comments

Popular posts from this blog

python - Selenium remoteWebDriver (& SauceLabs) Firefox moseMoveTo action exception -

html - How to custom Bootstrap grid height? -

transpose - Maple isnt executing function but prints function term -