From: Marcel Werk Date: Thu, 30 Jan 2014 20:48:20 +0000 (+0100) Subject: Fixed uninstall of templates X-Git-Tag: 2.0.3~61 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=8ea5b7308486190f6a7f2f0208df66c715002292;p=GitHub%2FWoltLab%2FWCF.git Fixed uninstall of templates --- diff --git a/wcfsetup/install/files/lib/system/package/plugin/TemplatePackageInstallationPlugin.class.php b/wcfsetup/install/files/lib/system/package/plugin/TemplatePackageInstallationPlugin.class.php index eeb7564e4e..1d61429b58 100644 --- a/wcfsetup/install/files/lib/system/package/plugin/TemplatePackageInstallationPlugin.class.php +++ b/wcfsetup/install/files/lib/system/package/plugin/TemplatePackageInstallationPlugin.class.php @@ -55,9 +55,12 @@ class TemplatePackageInstallationPlugin extends AbstractPackageInstallationPlugi */ public function uninstall() { // fetch templates from log - $sql = "SELECT templateName, application - FROM wcf".WCF_N."_template - WHERE packageID = ?"; + $sql = "SELECT template.templateName, template.application, + template_group.templateGroupFolderName + FROM wcf".WCF_N."_template template + LEFT JOIN wcf".WCF_N."_template_group template_group + ON (template_group.templateGroupID = template.templateGroupID) + WHERE packageID = ?"; $statement = WCF::getDB()->prepareStatement($sql); $statement->execute(array($this->installation->getPackageID())); @@ -67,7 +70,7 @@ class TemplatePackageInstallationPlugin extends AbstractPackageInstallationPlugi $templates[$row['application']] = array(); } - $templates[$row['application']][] = 'templates/'.$row['templateName'].'.tpl'; + $templates[$row['application']][] = 'templates/'.$row['templateGroupFolderName'].$row['templateName'].'.tpl'; } foreach ($templates as $application => $templateNames) {