Skip to content

Commit 225c2fe

Browse files
OskarStarkpbowyer
andcommitted
Apply suggestions from code review
Co-Authored-By: pbowyer <peter@mapledesign.co.uk>
1 parent f716e81 commit 225c2fe

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

workflow/usage.rst

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -583,12 +583,12 @@ requires:
583583
.. code-block:: xml
584584
585585
<!-- config/packages/workflow.xml -->
586-
<?xml version="1.0" encoding="utf-8" ?>
586+
<?xml version="1.0" encoding="UTF-8" ?>
587587
<container xmlns="http://symfony.com/schema/dic/services"
588588
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
589589
xmlns:framework="http://symfony.com/schema/dic/symfony"
590-
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd
591-
http://symfony.com/schema/dic/symfony http://symfony.com/schema/dic/symfony/symfony-1.0.xsd"
590+
xsi:schemaLocation="http://symfony.com/schema/dic/services https://symfony.com/schema/dic/services/services-1.0.xsd
591+
http://symfony.com/schema/dic/symfony https://symfony.com/schema/dic/symfony/symfony-1.0.xsd"
592592
>
593593
594594
<framework:config>
@@ -684,10 +684,11 @@ There is a shortcut that works with everything::
684684

685685
In a Flash message in your Controller::
686686

687-
// $transition = ...; (an instance of Transition)
688-
// $workflow is a Workflow instance retrieved from the Registry (see above)
689-
$title = $workflow->getMetadataStore()->getMetadata('title', $transition);
690-
$this->addFlash('info', "You have successfully applied the transition with title: '$title'");
687+
// $transition = ...; (an instance of Transition)
688+
689+
// $workflow is a Workflow instance retrieved from the Registry (see above)
690+
$title = $workflow->getMetadataStore()->getMetadata('title', $transition);
691+
$this->addFlash('info', "You have successfully applied the transition with title: '$title'");
691692

692693
Metadata can also be accessed in a Listener, from the Event object.
693694

0 commit comments

Comments
 (0)