mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-08 23:19:04 +01:00
guard against mail account looses all accounts it is valid for
This commit is contained in:
parent
9cf16b7423
commit
b8edbd159e
@ -1218,7 +1218,7 @@ class Account implements \ArrayAccess
|
|||||||
{
|
{
|
||||||
$old_account_ids[] = $row['account_id'];
|
$old_account_ids[] = $row['account_id'];
|
||||||
}
|
}
|
||||||
if (($ids_to_remove = array_diff($old_account_ids, (array)$data['account_id'])))
|
if ($data['account_id'] && ($ids_to_remove = array_diff($old_account_ids, (array)$data['account_id'])))
|
||||||
{
|
{
|
||||||
self::$db->delete(self::VALID_TABLE, $where+array(
|
self::$db->delete(self::VALID_TABLE, $where+array(
|
||||||
'account_id' => $ids_to_remove,
|
'account_id' => $ids_to_remove,
|
||||||
|
Loading…
Reference in New Issue
Block a user