From b1470fdbca185f74e70bb76887225748ae3f63d2 Mon Sep 17 00:00:00 2001 From: Stanislas Kita Date: Wed, 1 Oct 2025 10:42:49 +0200 Subject: [PATCH] Fix(Core): update classname generation method --- inc/container.class.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/inc/container.class.php b/inc/container.class.php index 7e906230..732b3dbb 100644 --- a/inc/container.class.php +++ b/inc/container.class.php @@ -767,8 +767,7 @@ public static function preItemPurge($item) foreach ($founded_containers as $container) { $itemtypes = json_decode($container['itemtypes']); if (in_array($itemtype, $itemtypes)) { - $classname = 'PluginFields' . $itemtype . getSingular($container['name']); - $classname = preg_replace('/s{2}$/i', 's', $classname); // in case name ends with 'ss' remove last 's' + $classname = self::getClassname($itemtype, $container['name']); $fields = new $classname(); $fields->deleteByCriteria(['items_id' => $item->fields['id']], true); }