$user_hash = \Session::get('auth-strategy.user', array());When i am doing
'username' => \Arr::get($user_hash, 'nickname'),
'fullname' => \Arr::get($user_hash, 'name'),
'email' => \Arr::get($user_hash, 'email'), ));
var_dump(Session::get('auth-strategy', array()))I get this
array (size=2)
'user' =>
array (size=5)
'name' => string 'Amit Yadav' (length=10)
'email' => string 'amityadav4a@gmail.com' (length=21)
'first_name' => string 'Amit' (length=4)
'last_name' => string 'Yadav' (length=5)
'image' => string 'https://lh3.googleusercontent.com/-HsEgUTlIKiU/AAAAAAAAAAI/AAAAAAAABOg/HgLKL83tJuo/photo.jpg' (length=92)
'authentication' =>
array (size=6)
'provider' => string 'Google' (length=6)
'uid' => string '10158226211236524812' (length=21)
'access_token' => string 'ya28.1.AADtM_XK3D5dJGijeqQK-EyvPpR4bhmR3kAv-fc_4wNWHTtstzeKO9f8HAlm8Skq7Q' (length=73)
'secret' => null
'expires' => string '2014-03-06T13:05:52+00:00' (length=25)
'refresh_token' => null
array (size=10)ie we don't have nickname to create new user. So we will redirect user to registration. Now if user with same email id is present in our system in this condition we wont be able to create new user or link this account to already registered user.
'id' => string '10158226211236524812' (length=21)
'email' => string 'amityadav4a@gmail.com' (length=21)
'verified_email' => boolean true
'name' => string 'Amit Yadav' (length=10)
'given_name' => string 'Amit' (length=4)
'family_name' => string 'Yadav' (length=5)
'link' => string 'https://plus.google.com/+AmitYadav4a' (length=36)
'picture' => string 'https://lh3.googleusercontent.com/-HsEgUTlIKiU/AAAAAAAAAAI/AAAAAAAABOg/HgLKL83tJuo/photo.jpg' (length=92)
'gender' => string 'male' (length=4)
'locale' => string 'en-GB' (length=5)
It looks like you're new here. If you want to get involved, click one of these buttons!