I want to save the uploads from the users in a path with the user ID. How can I integrate the ID into the path that automatically creates the folder?
if($r->hasFile('avatar'))
{
Auth::user()->update([
'avatar'=> $r->avatar->store('public/$id/avatar')
]);
}