From c2a85e7f7e842440d688ec3e8d56f44ae27b2595 Mon Sep 17 00:00:00 2001 From: mokaddem Date: Sun, 30 May 2021 11:05:07 +0200 Subject: [PATCH] fix: [sharinggroup:captureOrg/captureServer] Use the ID of the existing sharing group --- app/Model/SharingGroup.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Model/SharingGroup.php b/app/Model/SharingGroup.php index 950fa5971..e985fcf31 100644 --- a/app/Model/SharingGroup.php +++ b/app/Model/SharingGroup.php @@ -838,7 +838,7 @@ class SharingGroup extends AppModel $temp = $this->SharingGroupOrg->find('first', array( 'recursive' => -1, 'conditions' => array( - 'sharing_group_id' => $existingSG['SharingGroup']['id'], + 'sharing_group_id' => $sg_id, 'org_id' => $sg['SharingGroupOrg'][$k]['org_id'] ), )); @@ -891,7 +891,7 @@ class SharingGroup extends AppModel $temp = $this->SharingGroupServer->find('first', array( 'recursive' => -1, 'conditions' => array( - 'sharing_group_id' => $existingSG['SharingGroup']['id'], + 'sharing_group_id' => $sg_id, 'server_id' => $sg['SharingGroupServer'][$k]['server_id'] ), ));