From f0dfe3ae38c015173ff43c3da2f4a46d157e3d66 Mon Sep 17 00:00:00 2001 From: Artem Otliaguzov Date: Tue, 23 Jul 2024 10:33:56 +0200 Subject: [PATCH] make better notification in FolderDeleteMembership.php --- app/Jobs/FolderDeleteMembership.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Jobs/FolderDeleteMembership.php b/app/Jobs/FolderDeleteMembership.php index 7c936bf..8097188 100644 --- a/app/Jobs/FolderDeleteMembership.php +++ b/app/Jobs/FolderDeleteMembership.php @@ -51,6 +51,7 @@ public function handle(): void } $pathToFile = $federation->name.'/'.$entity->file; if(! Storage::disk($diskName)->exists($pathToFile)) { + NotificationService::sendEntityNotification($entity, new MembershipRejected($entity->entityid, $federation->name)); return; } @@ -62,7 +63,6 @@ public function handle(): void $lock->block(61); EntityFacade::deleteEntityMetadataFromFolder($entity->file, $federation->xml_id); - NotificationService::sendEntityNotification($entity, new MembershipRejected($entity->entityid, $federation->name)); RunMdaScript::dispatch($federation, $lock->owner()); } catch (Exception $e) {