File tree 1 file changed +8
-3
lines changed
src/Symfony/Bundle/FrameworkBundle/DependencyInjection 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -1195,9 +1195,14 @@ function ($a) {
1195
1195
->end ()
1196
1196
->arrayNode ('retry_strategy ' )
1197
1197
->addDefaultsIfNotSet ()
1198
- ->validate ()
1199
- ->ifTrue (function ($ v ) { return null !== $ v ['service ' ] && (isset ($ v ['max_retries ' ]) || isset ($ v ['delay ' ]) || isset ($ v ['multiplier ' ]) || isset ($ v ['max_delay ' ])); })
1200
- ->thenInvalid ('"service" cannot be used along with the other retry_strategy options. ' )
1198
+ ->beforeNormalization ()
1199
+ ->always (function ($ v ) {
1200
+ if (isset ($ v ['service ' ]) && (isset ($ v ['max_retries ' ]) || isset ($ v ['delay ' ]) || isset ($ v ['multiplier ' ]) || isset ($ v ['max_delay ' ]))) {
1201
+ throw new \InvalidArgumentException ('The "service" cannot be used along with the other "retry_strategy" options. ' );
1202
+ }
1203
+
1204
+ return $ v ;
1205
+ })
1201
1206
->end ()
1202
1207
->children ()
1203
1208
->scalarNode ('service ' )->defaultNull ()->info ('Service id to override the retry strategy entirely ' )->end ()
You can’t perform that action at this time.
0 commit comments