зеркало из https://github.com/nextcloud/server.git
Don't try to use backgroundjobs before the installtion is done
This commit is contained in:
Родитель
40de36a8f3
Коммит
e63633b5f3
12
lib/base.php
12
lib/base.php
|
@ -560,13 +560,15 @@ class OC {
|
|||
* register hooks for the cache
|
||||
*/
|
||||
public static function registerCacheHooks() {
|
||||
// register cache cleanup jobs
|
||||
try { //if this is executed before the upgrade to the new backgroundjob system is completed it will throw an exception
|
||||
@\OCP\BackgroundJob::registerJob('OC_Cache_FileGlobalGC');
|
||||
} catch (Exception $e) {
|
||||
if (OC_Config::getValue('installed', false)) { //don't try to do this before we are properly setup
|
||||
// register cache cleanup jobs
|
||||
try { //if this is executed before the upgrade to the new backgroundjob system is completed it will throw an exception
|
||||
\OCP\BackgroundJob::registerJob('OC_Cache_FileGlobalGC');
|
||||
} catch (Exception $e) {
|
||||
|
||||
}
|
||||
OC_Hook::connect('OC_User', 'post_login', 'OC_Cache_File', 'loginListener');
|
||||
}
|
||||
OC_Hook::connect('OC_User', 'post_login', 'OC_Cache_File', 'loginListener');
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Загрузка…
Ссылка в новой задаче