From 94e60f3679791863a1c9f861fabdd3247b231eae Mon Sep 17 00:00:00 2001 From: Sebastian Teumert Date: Tue, 26 Aug 2014 23:29:55 +0200 Subject: [PATCH] Add table name guessing --- wcfsetup/install/files/lib/data/DatabaseObject.class.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wcfsetup/install/files/lib/data/DatabaseObject.class.php b/wcfsetup/install/files/lib/data/DatabaseObject.class.php index de48f44ea7..81a941ca94 100644 --- a/wcfsetup/install/files/lib/data/DatabaseObject.class.php +++ b/wcfsetup/install/files/lib/data/DatabaseObject.class.php @@ -128,7 +128,8 @@ abstract class DatabaseObject implements IStorableObject { * @see \wcf\data\IStorableObject::getDatabaseTableName() */ public static function getDatabaseTableName() { - return 'wcf'.WCF_N.'_'.static::$databaseTableName; + $classParts = explode('\\', get_called_class()); + return $classParts[0].WCF_N.'_'.static::$databaseTableName; } /** -- 2.20.1