From: Alexander Ebert Date: Tue, 13 Sep 2011 12:46:14 +0000 (+0200) Subject: Fixed template compilation X-Git-Tag: 2.0.0_Beta_1~1765^2~23 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=48af062fe2436b60a8e71ab0c208dc2dd81c3230;p=GitHub%2FWoltLab%2FWCF.git Fixed template compilation Template owner's package id was previously used, but conflicts with application groups. Furthermore template listeners were not included due to lack of cache loading. --- diff --git a/wcfsetup/install/files/lib/system/template/TemplateEngine.class.php b/wcfsetup/install/files/lib/system/template/TemplateEngine.class.php index 219ef32c8a..f203d51818 100644 --- a/wcfsetup/install/files/lib/system/template/TemplateEngine.class.php +++ b/wcfsetup/install/files/lib/system/template/TemplateEngine.class.php @@ -297,7 +297,7 @@ class TemplateEngine extends SingletonFactory { } $tplPackageID = $this->getPackageID($templateName, $packageID); - $compiledFilename = $this->getCompiledFilename($templateName, $tplPackageID); + $compiledFilename = $this->getCompiledFilename($templateName, $packageID); $sourceFilename = $this->getSourceFilename($templateName, $tplPackageID); // check if compilation is necessary @@ -752,6 +752,8 @@ class TemplateEngine extends SingletonFactory { * @return string */ public function getTemplateListenerCode($templateName, $eventName) { + $this->loadTemplateListenerCode($templateName); + if (isset($this->templateListeners[$templateName][$eventName])) { return implode("\n", $this->templateListeners[$templateName][$eventName]); }