Skip to content

Commit ded1607

Browse files
committed
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
2 parents 908e719 + f7961bb commit ded1607

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

DependencyInjection/FrameworkExtension.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -397,6 +397,10 @@ private function registerWorkflowConfiguration(array $workflows, ContainerBuilde
397397
return;
398398
}
399399

400+
if (!class_exists(Workflow\Workflow::class)) {
401+
throw new LogicException('Workflow support cannot be enabled as the Workflow component is not installed.');
402+
}
403+
400404
$loader->load('workflow.xml');
401405

402406
$registryDefinition = $container->getDefinition('workflow.registry');

composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
"symfony/translation": "~3.2",
5151
"symfony/templating": "~2.8|~3.0",
5252
"symfony/validator": "~3.2",
53+
"symfony/workflow": "~3.2",
5354
"symfony/yaml": "~3.2",
5455
"symfony/property-info": "~3.1",
5556
"doctrine/annotations": "~1.0",

0 commit comments

Comments
 (0)