From 7e69e5a54874c24d56daae76bdc0d83cda0c6383 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=B4me=20Chilliet?= <come.bernigaud@opensides.be> Date: Wed, 8 Jun 2016 05:38:47 +0200 Subject: [PATCH] Fixes #4856 Put back copypastehandler for deprecated tabs constructor, needed by systemManagement --- include/class_CopyPasteHandler.inc | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/include/class_CopyPasteHandler.inc b/include/class_CopyPasteHandler.inc index 914e88f68..fb0fb71c4 100644 --- a/include/class_CopyPasteHandler.inc +++ b/include/class_CopyPasteHandler.inc @@ -167,7 +167,18 @@ class CopyPasteHandler return array(); } - $entry['object'] = objects::open($entry['dn'], $entry['type']); + if (isset($entry['type'])) { + $entry['object'] = objects::open($entry['dn'], $entry['type']); + } else { + trigger_error('Call to deprecated tabs constructor'); + // old way + $tab_c = $entry['tab_class']; + $tab_o = $entry['tab_object']; + $tab_a = $entry['tab_acl_category']; + + // Deprecated + $entry['object'] = new $tab_c(NULL, $config->data['TABS'][$tab_o], $entry['dn'], $tab_a); + } $entry['object']->set_acl_base($base); if ($entry['parent'] !== NULL) { -- GitLab