lundi 8 juillet 2019

How to set a new value for auth()->guard('user')->id?

The following code,

$userData = auth()->guard('user')->user();

gives the user data. How can I set the value of a field from auth()->guard('user')?

Say something like this:- auth()->guard('user')->fname = 'Test'; when $userData['fname'] is empty.

Is it at all possible?



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire