diff options
Diffstat (limited to 'lib/public/util.php')
-rw-r--r-- | lib/public/util.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/public/util.php b/lib/public/util.php index 652df5192cf..1ba091d1952 100644 --- a/lib/public/util.php +++ b/lib/public/util.php @@ -654,6 +654,7 @@ class Util { return \OC_Util::isDefaultExpireDateEnforced(); } + protected static $needUpgradeCache = null; /** * Checks whether the current version needs upgrade. @@ -662,6 +663,9 @@ class Util { * @since 7.0.0 */ public static function needUpgrade() { - return \OC_Util::needUpgrade(\OC::$server->getConfig()); + if (!isset(self::$needUpgradeCache)) { + self::$needUpgradeCache=\OC_Util::needUpgrade(\OC::$server->getConfig()); + } + return self::$needUpgradeCache; } } |