bug #22040 [FrameworkBundle] improve message when workflows are missing (xabbuh)

This PR was merged into the 3.2 branch.

Discussion
----------

[FrameworkBundle] improve message when workflows are missing

| Q             | A
| ------------- | ---
| Branch?       | 3.2
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

Commits
-------

46c12c9d1d improve message when workflows are missing
This commit is contained in:
Grégoire Pineau 2017-03-17 16:59:28 +01:00
commit d50885cc16
2 changed files with 5 additions and 0 deletions

View File

@ -397,6 +397,10 @@ class FrameworkExtension extends Extension
return;
}
if (!class_exists(Workflow\Workflow::class)) {
throw new LogicException('Workflow support cannot be enabled as the Workflow component is not installed.');
}
$loader->load('workflow.xml');
$registryDefinition = $container->getDefinition('workflow.registry');

View File

@ -50,6 +50,7 @@
"symfony/translation": "~3.2",
"symfony/templating": "~2.8|~3.0",
"symfony/validator": "~3.2",
"symfony/workflow": "~3.2",
"symfony/yaml": "~3.2",
"symfony/property-info": "~3.1",
"doctrine/annotations": "~1.0",