Making visible or hidden attributes from Eloquent temporarily code example
Example: Making visible or hidden attributes from Eloquent temporarily
$users = $users->makeVisible(['address', 'phone_number']);
$users = $users->makeHidden(['address', 'phone_number']);