From: Morris Jobke Date: Sun, 21 May 2017 23:38:16 +0000 (-0500) Subject: Reset opcache if update is detected X-Git-Tag: v12.0.1RC1~135^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=refs%2Fpull%2F5017%2Fhead;p=nextcloud-server.git Reset opcache if update is detected This even works if opcache_reset is in the disabled_functions php.ini setting. Signed-off-by: Morris Jobke --- diff --git a/lib/base.php b/lib/base.php index 38e9fb8e498..226aeeb727f 100644 --- a/lib/base.php +++ b/lib/base.php @@ -292,6 +292,9 @@ class OC { */ public static function checkUpgrade($showTemplate = true) { if (\OCP\Util::needUpgrade()) { + if (function_exists('opcache_reset')) { + opcache_reset(); + } $systemConfig = \OC::$server->getSystemConfig(); if ($showTemplate && !$systemConfig->getValue('maintenance', false)) { self::printUpgradePage();