fix sql error when deleting a user without distribution lists

This commit is contained in:
Ralf Becker 2013-09-03 16:05:32 +00:00
parent d0f967bdd8
commit 281dfe0fee

View File

@ -793,9 +793,9 @@ class addressbook_so
{ {
$this->somain->delete(array('owner' => $account_id)); // so_sql_cf::delete() takes care of cfs too $this->somain->delete(array('owner' => $account_id)); // so_sql_cf::delete() takes care of cfs too
if(method_exists($this->somain, 'get_lists')) if (method_exists($this->somain, 'get_lists') &&
($lists = $this->somain->get_lists($account_id)))
{ {
$lists = $this->somain->get_lists($account_id);
$this->somain->delete_list(array_keys($lists)); $this->somain->delete_list(array_keys($lists));
} }
} }