Skip to content

Commit fe5aa2f

Browse files
committed
fix: don't make ICacheFactory depend on database
Signed-off-by: Robin Appelman <robin@icewind.nl>
1 parent c5721a1 commit fe5aa2f

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

lib/private/Server.php

+8-8
Original file line numberDiff line numberDiff line change
@@ -643,11 +643,11 @@ public function __construct($webRoot, \OC\Config $config) {
643643
ArrayCache::class,
644644
ArrayCache::class
645645
);
646-
/** @var \OCP\IConfig $config */
647-
$config = $c->get(\OCP\IConfig::class);
646+
/** @var SystemConfig $config */
647+
$config = $c->get(SystemConfig::class);
648648

649-
if ($config->getSystemValueBool('installed', false) && !(defined('PHPUNIT_RUN') && PHPUNIT_RUN)) {
650-
if (!$config->getSystemValueBool('log_query')) {
649+
if ($config->getValue('installed', false) && !(defined('PHPUNIT_RUN') && PHPUNIT_RUN)) {
650+
if (!$config->getValue('log_query')) {
651651
try {
652652
$v = \OC_App::getAppVersions();
653653
} catch (\Doctrine\DBAL\Exception $e) {
@@ -671,10 +671,10 @@ public function __construct($webRoot, \OC\Config $config) {
671671
return new \OC\Memcache\Factory($prefix,
672672
$c->get(LoggerInterface::class),
673673
$profiler,
674-
$config->getSystemValue('memcache.local', null),
675-
$config->getSystemValue('memcache.distributed', null),
676-
$config->getSystemValue('memcache.locking', null),
677-
$config->getSystemValueString('redis_log_file')
674+
$config->getValue('memcache.local', null),
675+
$config->getValue('memcache.distributed', null),
676+
$config->getValue('memcache.locking', null),
677+
$config->getValue('redis_log_file')
678678
);
679679
}
680680
return $arrayCacheFactory;

0 commit comments

Comments
 (0)