Bugfixes for Kimai 1.4.1 (#1158)
* fix missing translation for preset datatable headers * better dependency check for avatar service * show only own teams to teamleads
This commit is contained in:
@@ -122,7 +122,7 @@ class AvatarService
|
||||
|
||||
public function generateAvatar(User $profile, bool $regenerate = false): bool
|
||||
{
|
||||
if (!extension_loaded('gd')) {
|
||||
if (!$this->hasDependencies()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -152,4 +152,9 @@ class AvatarService
|
||||
|
||||
return $this->getAvatarUrl($profile);
|
||||
}
|
||||
|
||||
public function hasDependencies(): bool
|
||||
{
|
||||
return extension_loaded('gd') && function_exists('imagettfbbox');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user