mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-06-25 20:31:31 +02:00
fix TypeError: array_column(): Argument #1 ($array) must be of type array, null given (0)
This commit is contained in:
parent
fb6f1654c7
commit
43bb78aeec
@ -399,7 +399,7 @@ class addressbook_import_contacts_csv extends importexport_basic_import_csv {
|
|||||||
protected function empty_addressbook($addressbook, $ids)
|
protected function empty_addressbook($addressbook, $ids)
|
||||||
{
|
{
|
||||||
// Get all IDs in addressbook
|
// Get all IDs in addressbook
|
||||||
$contacts = $this->bocontacts->search(array('owner' => $addressbook), true);
|
$contacts = $this->bocontacts->search(array('owner' => $addressbook), true) ?? [];
|
||||||
$contacts = array_column($contacts, 'id');
|
$contacts = array_column($contacts, 'id');
|
||||||
|
|
||||||
$delete = array_diff($contacts, $ids);
|
$delete = array_diff($contacts, $ids);
|
||||||
@ -518,4 +518,4 @@ class addressbook_import_contacts_csv extends importexport_basic_import_csv {
|
|||||||
public function get_results() {
|
public function get_results() {
|
||||||
return $this->results;
|
return $this->results;
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user