From: hickert Date: Tue, 29 Nov 2005 13:18:32 +0000 (+0000) Subject: Prevent automatic remove of phpgwaccount when not in tabbed mode X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=0033e967f45d6e3bea8a8deba89d400488cb9d9b;p=gosa.git Prevent automatic remove of phpgwaccount when not in tabbed mode git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2131 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/personal/connectivity/class_phpgwAccount.inc b/plugins/personal/connectivity/class_phpgwAccount.inc index e119980c9..b4d8df5fa 100644 --- a/plugins/personal/connectivity/class_phpgwAccount.inc +++ b/plugins/personal/connectivity/class_phpgwAccount.inc @@ -107,21 +107,22 @@ class phpgwAccount extends plugin function save() { plugin::save(); - - /* Write back to ldap */ - $ldap= $this->config->get_ldap_link(); - $ldap->cd($this->dn); - $ldap->modify($this->attrs); - show_ldap_error($ldap->get_error()); - - /* Optionally execute a command after we're done */ - if ($this->initially_was_account == $this->is_account){ - if ($this->is_modified){ - $this->handle_post_events("mofify"); + if ($this->parent != NULL){ + /* Write back to ldap */ + $ldap= $this->config->get_ldap_link(); + $ldap->cd($this->dn); + $ldap->modify($this->attrs); + show_ldap_error($ldap->get_error()); + + /* Optionally execute a command after we're done */ + if ($this->initially_was_account == $this->is_account){ + if ($this->is_modified){ + $this->handle_post_events("mofify"); + } + } else { + $this->handle_post_events("add"); + } } - } else { - $this->handle_post_events("add"); - } } }