Skip to content

Commit

Permalink
Tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
javiereguiluz committed Mar 25, 2024
1 parent 0435d4a commit b78255f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions workflow.rst
Expand Up @@ -520,16 +520,16 @@ workflow leaves a place::
{
return [
LeaveEvent::getName('blog_publishing') => 'onLeave',
// if you prefer, you can write the event name manually like this:
// 'workflow.blog_publishing.leave' => 'onLeave',
];
}
}

.. tip::

All built-in workflow events define the ``getName(?string $workflowName, ?string $transitionOrPlaceName)``
method to build the full event name (e.g. ``'workflow.blog_publishing.leave'``)
without having to work with strings.

method to build the full event name without having to deal with strings.
You can also use this method in your custom events via the
:class:`Symfony\\Component\\Workflow\\Event\\EventNameTrait`.

Expand Down

0 comments on commit b78255f

Please sign in to comment.