Additional condition for displaying an avatar in the profile

This commit is contained in:
Visman 2018-09-05 14:49:38 +07:00
parent 321ea884eb
commit 5f90f4794e

View file

@ -61,7 +61,7 @@ class View extends Profile
$fields[] = [ $fields[] = [
'type' => 'endwrap', 'type' => 'endwrap',
]; ];
if ($this->rules->useAvatar) { if ($this->rules->useAvatar && $this->curUser->avatar) {
$fields['avatar'] = [ $fields['avatar'] = [
'type' => 'yield', 'type' => 'yield',
'caption' => \ForkBB\__('Avatar'), 'caption' => \ForkBB\__('Avatar'),