Skip to content

Commit

Permalink
[BUGFIX] Use non-static method getCache in Avatar class
Browse files Browse the repository at this point in the history
The getCache method is not static but called as static twice.
Use $this->getCache() instead.

Resolves: #85879
Releases: master,8.7
Change-Id: Icfb28989c201894d0bfd2867642d7703426fabc2
Reviewed-on: https://review.typo3.org/57935
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Markus Klein <markus.klein@typo3.org>
Tested-by: Markus Klein <markus.klein@typo3.org>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
  • Loading branch information
wouter90 authored and lolli42 committed Aug 16, 2018
1 parent b364d86 commit 551f4fc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions typo3/sysext/backend/Classes/Backend/Avatar/Avatar.php
Expand Up @@ -59,7 +59,7 @@ public function render(array $backendUser = null, int $size = 32, bool $showIcon
(string)$showIcon
);

$avatar = static::getCache()->get($cacheId);
$avatar = $this->getCache()->get($cacheId);

if (!$avatar) {
$this->validateSortAndInitiateAvatarProviders();
Expand All @@ -71,7 +71,7 @@ public function render(array $backendUser = null, int $size = 32, bool $showIcon
'backendUser' => $backendUser
]);
$avatar = $view->render();
static::getCache()->set($cacheId, $avatar);
$this->getCache()->set($cacheId, $avatar);
}

return $avatar;
Expand Down

0 comments on commit 551f4fc

Please sign in to comment.