Answer the question
In order to leave comments, you need to log in
How to create a custom user object?
I need to create a custom user object:
$user = new User($user_id);
или
$user = user($user_id);
Auth::user()->getMedia('passport_heads')->first()->getUrl('thumb')
Answer the question
In order to leave comments, you need to log in
The user is a regular eloquent model, and you can work with it in the same way as with the rest, see the help.
https://laravel.com/docs/8.x/eloquent#retrieving-s...
Anton Anton , https://laravel.com/docs/8.x/eloquent#retrieving-s...
Ps: I don't know how else to close the question. Anton, if you see, then leave an answer so that I choose your answer as a solution
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question