From 45d34ee43f1687ef5167c3e9029c87b88b7c864c Mon Sep 17 00:00:00 2001 From: mokaddem Date: Tue, 29 Jun 2021 11:37:49 +0200 Subject: [PATCH] fix: [inbox:createEntry] Ignore user alignment with organisation when creating entry --- src/Model/Table/InboxTable.php | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/Model/Table/InboxTable.php b/src/Model/Table/InboxTable.php index 21d6da6..716d246 100644 --- a/src/Model/Table/InboxTable.php +++ b/src/Model/Table/InboxTable.php @@ -75,15 +75,15 @@ class InboxTable extends AppTable $errors[] = __('Unkown brood `{0}`', $entryData['data']['cerebrateURL']); } - $found = false; - foreach ($user->individual->organisations as $organisations) { - if ($organisations->id == $brood->organisation_id) { - $found = true; - } - } - if (!$found) { - $errors[] = __('User `{0}` is not part of the brood\'s organisation. Make sure `{0}` is aligned with the organisation owning the brood.', $user->individual->email); - } + // $found = false; + // foreach ($user->individual->organisations as $organisations) { + // if ($organisations->id == $brood->organisation_id) { + // $found = true; + // } + // } + // if (!$found) { + // $errors[] = __('User `{0}` is not part of the brood\'s organisation. Make sure `{0}` is aligned with the organisation owning the brood.', $user->individual->email); + // } return $errors; }