$user->avatar()
Returns the File object for the avatar or null
$user->avatar(): Kirby\Cms\File|null
Return types
Kirby\Cms\File
ornull
Parent class
Avatar storage
The user avatar is stored in the user account folder in /site/accounts
..
Avatars can be jpg, gif or png files and must be called profile
Examples
<?php if ($avatar = $kirby->user('bastian@example.com')->avatar()): ?>
<img src="<?= $avatar->url() ?>" alt="Bastian's avatar">
<?php endif ?>