aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorFerdinand Thiessen <opensource@fthiessen.de>2025-01-24 13:14:19 +0100
committerbackportbot[bot] <backportbot[bot]@users.noreply.github.com>2025-01-24 18:12:18 +0000
commit99e76d7a99b68d122340b76d726b2f40f354d6f9 (patch)
tree421d1e920f000d8f707749da6c9d7e7b3b238499 /lib
parentae3e26024e505cfae3196471525a701a2e87e7dd (diff)
downloadnextcloud-server-99e76d7a99b68d122340b76d726b2f40f354d6f9.tar.gz
nextcloud-server-99e76d7a99b68d122340b76d726b2f40f354d6f9.zip
fix(TemplateLayout): `core` is not an app but the server itself
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/TemplateLayout.php17
1 files changed, 11 insertions, 6 deletions
diff --git a/lib/private/TemplateLayout.php b/lib/private/TemplateLayout.php
index 001ef3afca5..e52ef702ad3 100644
--- a/lib/private/TemplateLayout.php
+++ b/lib/private/TemplateLayout.php
@@ -344,13 +344,18 @@ class TemplateLayout extends \OC_Template {
return false;
}
- $appVersion = $this->appManager->getAppVersion($appId);
- // For shipped apps the app version is not a single source of truth, we rather also need to consider the Nextcloud version
- if ($this->appManager->isShipped($appId)) {
- $appVersion .= '-' . self::$versionHash;
- }
+ if ($appId === 'core') {
+ // core is not a real app but the server itself
+ $hash = self::$versionHash;
+ } else {
+ $appVersion = $this->appManager->getAppVersion($appId);
+ // For shipped apps the app version is not a single source of truth, we rather also need to consider the Nextcloud version
+ if ($this->appManager->isShipped($appId)) {
+ $appVersion .= '-' . self::$versionHash;
+ }
- $hash = substr(md5($appVersion), 0, 8);
+ $hash = substr(md5($appVersion), 0, 8);
+ }
self::$cacheBusterCache[$path] = $hash;
}