From 86acd535c243569fda7c1a2957073509c7e94f89 Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Wed, 15 Jul 2015 16:14:48 +0200 Subject: [PATCH] use the database backend for locking if no memcache is configured for it --- lib/private/server.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/private/server.php b/lib/private/server.php index 12981fe7f1..51e7040543 100644 --- a/lib/private/server.php +++ b/lib/private/server.php @@ -48,6 +48,7 @@ use OC\Diagnostics\QueryLogger; use OC\Files\Node\Root; use OC\Files\View; use OC\Http\Client\ClientService; +use OC\Lock\DBLockingProvider; use OC\Lock\MemcacheLockingProvider; use OC\Lock\NoopLockingProvider; use OC\Mail\Mailer; @@ -434,10 +435,7 @@ class Server extends SimpleContainer implements IServerContainer { if (!($memcache instanceof \OC\Memcache\NullCache)) { return new MemcacheLockingProvider($memcache); } - throw new HintException( - 'File locking is enabled but the locking cache class was not found', - 'Please check the "memcache.locking" setting and make sure the matching PHP module is installed and enabled' - ); + return new DBLockingProvider($c->getDatabaseConnection()); } return new NoopLockingProvider(); });