Log step key data
[MAILPOET-5568]
This commit is contained in:
@ -4,6 +4,7 @@ namespace MailPoet\Automation\Engine\Control;
|
||||
|
||||
use DateTimeImmutable;
|
||||
use MailPoet\Automation\Engine\Data\AutomationRunLog;
|
||||
use MailPoet\Automation\Engine\Data\Step;
|
||||
use MailPoet\Automation\Engine\Hooks;
|
||||
use MailPoet\Automation\Engine\Storage\AutomationRunLogStorage;
|
||||
use MailPoet\InvalidStateException;
|
||||
@ -46,6 +47,12 @@ class StepRunLogger {
|
||||
$this->getLog();
|
||||
}
|
||||
|
||||
public function logStepData(Step $step): void {
|
||||
$log = $this->getLog();
|
||||
$log->setStepKey($step->getKey());
|
||||
$this->automationRunLogStorage->updateAutomationRunLog($log);
|
||||
}
|
||||
|
||||
public function logSuccess(): void {
|
||||
$log = $this->getLog();
|
||||
$log->setStatus(AutomationRunLog::STATUS_COMPLETE);
|
||||
|
Reference in New Issue
Block a user