From 4b2fa0591c6e9cdf500cba5e6a67a39a282ae0df Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 23 Nov 2010 07:14:58 +0000 Subject: [PATCH] Only act on ArpNewDevice check while ArpNewDevice class is available. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20327 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-plugins/systems/admin/systems/class_servGeneric.inc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gosa-plugins/systems/admin/systems/class_servGeneric.inc b/gosa-plugins/systems/admin/systems/class_servGeneric.inc index 1adcf073b..332b49711 100644 --- a/gosa-plugins/systems/admin/systems/class_servGeneric.inc +++ b/gosa-plugins/systems/admin/systems/class_servGeneric.inc @@ -84,7 +84,8 @@ class servgeneric extends plugin $ui= get_userinfo(); $this->base= dn2base(session::global_is_set("CurrentMainBase")?"cn=dummy,".session::global_get("CurrentMainBase"):$ui->dn); $this->cn= ""; - } elseif(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", $this->dn)){ + } elseif(class_available("ArpNewDevice") && + preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", $this->dn)){ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", "", $this->dn); } else { $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("servgeneric", "serverRDN"), '/')."/i", "", $this->dn); -- 2.30.2