Code

Removed show_ldap_error() calls
[gosa.git] / gosa-plugins / webdav / personal / connectivity / webdav / class_webdavAccount.inc
index 4d7c179ded461f579c81029d8f377cf5d72db18f..a16ce246aa278317d232b01c278c6e096ccc81b3 100644 (file)
@@ -80,7 +80,9 @@ class webdavAccount extends plugin
       /* Log last action */
       new log("remove","users/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
 
-      show_ldap_error($ldap->get_error(), sprintf(_("Removing of user/webDAV account with dn '%s' failed."),$this->dn));
+      if (!$ldap->success()){
+        msg_dialog::display(_("LDAP error"), msgPool::ldaperror($ldap->get_error(), $this->dn, LDAP_MOD, get_class()));
+      }
 
       /* Optionally execute a command after we're done */
       $this->handle_post_events('remove',array("uid" => $this->uid));
@@ -134,7 +136,9 @@ class webdavAccount extends plugin
         new log("create","users/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
       }
 
-      show_ldap_error($ldap->get_error(), sprintf(_("Saving of user/webDAV account with dn '%s' failed."),$this->dn));
+      if (!$ldap->success()){
+        msg_dialog::display(_("LDAP error"), msgPool::ldaperror($ldap->get_error(), $this->dn, LDAP_MOD, get_class()));
+      }
 
       /* Optionally execute a command after we're done */
       if ($this->initially_was_account == $this->is_account){