From eb105a5b5c6816a36d316f7c488360ccba1769ae Mon Sep 17 00:00:00 2001 From: Curtis Conard Date: Wed, 1 Nov 2023 14:42:53 -0400 Subject: [PATCH] missing casts --- src/CommonITILObject.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/CommonITILObject.php b/src/CommonITILObject.php index 6371e53b55f..45bfae9d912 100644 --- a/src/CommonITILObject.php +++ b/src/CommonITILObject.php @@ -123,7 +123,7 @@ public function loadUsers(): void { if (!empty($this->userlinkclass) && !$this->isNewItem()) { $class = new $this->userlinkclass(); - $this->lazy_loaded_users = $class->getActors($this->fields['id']); + $this->lazy_loaded_users = $class->getActors((int) $this->fields['id']); } else { $this->lazy_loaded_users = []; } @@ -138,7 +138,7 @@ protected function loadGroups(): void { if (!empty($this->grouplinkclass) && !$this->isNewItem()) { $class = new $this->grouplinkclass(); - $this->lazy_loaded_groups = $class->getActors($this->fields['id']); + $this->lazy_loaded_groups = $class->getActors((int) $this->fields['id']); } else { $this->lazy_loaded_groups = []; } @@ -153,7 +153,7 @@ public function loadSuppliers(): void { if (!empty($this->supplierlinkclass) && !$this->isNewItem()) { $class = new $this->supplierlinkclass(); - $this->lazy_loaded_suppliers = $class->getActors($this->fields['id']); + $this->lazy_loaded_suppliers = $class->getActors((int) $this->fields['id']); } else { $this->lazy_loaded_suppliers = []; } @@ -4157,7 +4157,7 @@ public static function processMassiveActionsForOneItemtype( } } $linkclass = new $item->supplierlinkclass(); - foreach ($linkclass->getActors($id) as $users) { + foreach ($linkclass->getActors((int) $id) as $users) { foreach ($users as $data) { $data['use_notification'] = $input['use_notification']; $linkclass->update($data);