only decorate when an event dispatcher was passed
This commit is contained in:
parent
205cd7a0fb
commit
f19f28a41d
@ -43,7 +43,7 @@ class Workflow implements WorkflowInterface
|
||||
{
|
||||
$this->definition = $definition;
|
||||
$this->markingStore = $markingStore ?: new MultipleStateMarkingStore();
|
||||
$this->dispatcher = LegacyEventDispatcherProxy::decorate($dispatcher);
|
||||
$this->dispatcher = null !== $dispatcher ? LegacyEventDispatcherProxy::decorate($dispatcher) : null;
|
||||
$this->name = $name;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user