diff --git a/public_html/includes/class/class.LSldapObject.php b/public_html/includes/class/class.LSldapObject.php index 4721cf71..abd14e85 100644 --- a/public_html/includes/class/class.LSldapObject.php +++ b/public_html/includes/class/class.LSldapObject.php @@ -404,8 +404,6 @@ class LSldapObject { $LSform=false; } foreach($this -> attrs as $attr_name => $attr) { - if ($LSform && (!$LSform -> hasElement($attr_name) || $LSform -> isFreeze($attr_name))) - continue; $attr_values = $attr -> getValue(); if (!$attr -> isValidate()) { if($attr -> isUpdate()) { @@ -427,6 +425,10 @@ class LSldapObject { } } else { + // Don't blame on non-create form for attributes not-present in form (or freezed) + if ($LSform && $idFrom != 'create' && (!$LSform -> hasElement($attr_name) || $LSform -> isFreeze($attr_name))) + continue; + LSerror :: addErrorCode('LSattribute_06',$attr -> getLabel()); $retval = false; }