function avatar(App\Models\User $user, $size) { $fname = base64_encode($user->email) . ".png?tid=" . $user->getAvatarId(); return url("avatar/{$size}/{$fname}"); }