summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 3338ab4)
raw | patch | inline | side by side (parent: 3338ab4)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 13 Sep 2007 09:26:33 +0000 (09:26 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 13 Sep 2007 09:26:33 +0000 (09:26 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@7287 594d385d-05f5-0310-b6e9-bd551577e9d8
include/class_plugin.inc | patch | blob | history |
index eb4d40a8fe4218e862e2a7088a4e8d0d14d3ba9f..47dd20c517adc7de44330e857ac973e9059d537f 100644 (file)
--- a/include/class_plugin.inc
+++ b/include/class_plugin.inc
/* Get current objectClasses in order to add the required ones */
$ldap->cat($this->dn);
$tmp= $ldap->fetch ();
- $oc= array();
+ $oc= array();
if (isset($tmp['objectClass'])){
$oc= $tmp['objectClass'];
unset($oc['count']);
$ldap->cat($this->dn);
$tmp= $ldap->fetch ();
-
+
+ $oc= array();
if (isset($tmp['objectClass'])){
$oc= $tmp["objectClass"];
$this->is_new= FALSE;
+ unset($oc['count']);
} else {
- $oc= array("count" => 0);
$this->is_new= TRUE;
}
/* Load (minimum) attributes, add missing ones */
- $this->attrs['objectClass']= $this->objectclasses;
- for ($i= 0; $i<$oc["count"]; $i++){
- if (!in_array_ics($oc[$i], $this->objectclasses)){
- $this->attrs['objectClass'][]= $oc[$i];
- }
- }
+ $this->attrs['objectClass']= gosa_array_merge($oc,$this->objectclasses);
/* Copy standard attributes */
foreach ($this->attributes as $val){