From 4b5bdfe2ec94c40043d9c1030f34ee85d6a475da Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Tue, 3 Mar 2015 19:52:18 +0100 Subject: [PATCH] Loosening check for drop table --- .../package/PackageInstallationSQLParser.class.php | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/wcfsetup/install/files/lib/system/package/PackageInstallationSQLParser.class.php b/wcfsetup/install/files/lib/system/package/PackageInstallationSQLParser.class.php index ba3726eb9e..268c7e5347 100644 --- a/wcfsetup/install/files/lib/system/package/PackageInstallationSQLParser.class.php +++ b/wcfsetup/install/files/lib/system/package/PackageInstallationSQLParser.class.php @@ -409,14 +409,8 @@ class PackageInstallationSQLParser extends SQLParser { protected function executeDropTableStatement($tableName) { if ($this->test) { if (in_array($tableName, $this->existingTables)) { - if (isset($this->knownTables[$tableName])) { - if ($this->knownTables[$tableName] != $this->package->packageID) { - throw new SystemException("Cannot drop table '".$tableName."'. A package can only drop own tables."); - } - } - else { - if (!isset($this->conflicts['DROP TABLE'])) $this->conflicts['DROP TABLE'] = array(); - $this->conflicts['DROP TABLE'][] = $tableName; + if (isset($this->knownTables[$tableName]) && $this->knownTables[$tableName] != $this->package->packageID) { + throw new SystemException("Cannot drop table '".$tableName."'. A package can only drop own tables."); } } } -- 2.20.1