mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
fix: lib/private/TaskProcessing/Manager.php
Co-authored-by: Julien Veyssier <julien-nc@posteo.net> Signed-off-by: Marcel Klehr <mklehr@gmx.net>
This commit is contained in:
parent
49a52126ab
commit
f127ab10da
1 changed files with 4 additions and 2 deletions
|
|
@ -765,8 +765,10 @@ class Manager implements IManager {
|
|||
}
|
||||
|
||||
public function getAvailableTaskTypes(bool $showDisabled = false): array {
|
||||
if ($this->availableTaskTypes === null && $this->distributedCache->get('available_task_types_v2') !== null) {
|
||||
$this->availableTaskTypes = unserialize($this->distributedCache->get('available_task_types_v2'));
|
||||
if ($this->availableTaskTypes === null) {
|
||||
$cachedValue = $this->distributedCache->get('available_task_types_v2');
|
||||
if ($cachedValue !== null) {
|
||||
$this->availableTaskTypes = unserialize($cachedValue);
|
||||
}
|
||||
// Either we have no cache or showDisabled is turned on, which we don't want to cache, ever.
|
||||
if ($this->availableTaskTypes === null || $showDisabled) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue