Verified Commit 8d6809ad authored by Cyril Vazquez's avatar Cyril Vazquez
Browse files

Fix error on rejection: Send all message instead of message id

parent 73cb686b
Pipeline #7000 failed with stages
...@@ -209,11 +209,6 @@ class ArchiveRestitutionRequest extends abstractMessage ...@@ -209,11 +209,6 @@ class ArchiveRestitutionRequest extends abstractMessage
$this->generate($message); $this->generate($message);
$this->save($message); $this->save($message);
} }
$operationResult = true;
$message->object->unitIdentifier = $message->unitIdentifier;
$this->create($message);
} catch (\Exception $e) { } catch (\Exception $e) {
$message->status = "invalid"; $message->status = "invalid";
$this->create($message); $this->create($message);
...@@ -223,12 +218,14 @@ class ArchiveRestitutionRequest extends abstractMessage ...@@ -223,12 +218,14 @@ class ArchiveRestitutionRequest extends abstractMessage
throw $e; throw $e;
} }
$this->create($message);
$this->lifeCycleJournalController->logEvent( $this->lifeCycleJournalController->logEvent(
'medona/sending', 'medona/sending',
'medona/message', 'medona/message',
$message->messageId, $message->messageId,
$message, $message,
$operationResult true
); );
return $message; return $message;
...@@ -354,7 +351,7 @@ class ArchiveRestitutionRequest extends abstractMessage ...@@ -354,7 +351,7 @@ class ArchiveRestitutionRequest extends abstractMessage
); );
$archiveRestitutionRequestReplyController = \laabs::newController('medona/ArchiveRestitutionRequestReply'); $archiveRestitutionRequestReplyController = \laabs::newController('medona/ArchiveRestitutionRequestReply');
$replyMessage = $archiveRestitutionRequestReplyController->send($messageId, "400", $comment); $replyMessage = $archiveRestitutionRequestReplyController->send($message, "400", $comment);
return $replyMessage; return $replyMessage;
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment