Skip to content

Commit

Permalink
bug #28639 [DI] add missing sprintf argument in AbstractRecursivePass…
Browse files Browse the repository at this point in the history
…::getExpressionLanguage (kaznovac)

This PR was merged into the 4.2-dev branch.

Discussion
----------

[DI] add missing sprintf argument in AbstractRecursivePass::getExpressionLanguage

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| License       | MIT

runtime exception in AbstractRecursivePass::getExpressionLanguage is referencing service as third parameter in sprintf, but none was given.

Commits
-------

dc5bf84 third parameter of sprintf missing in AbstractRecursivePass::getExpressionLanguage
  • Loading branch information
nicolas-grekas committed Sep 29, 2018
2 parents 15aa25a + dc5bf84 commit d5e3f2f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ private function getExpressionLanguage()
$arg = $this->processValue(new Reference($id));
$this->inExpression = false;
if (!$arg instanceof Reference) {
throw new RuntimeException(sprintf('"%s::processValue()" must return a Reference when processing an expression, %s returned for service("%s").', \get_class($this), \is_object($arg) ? \get_class($arg) : \gettype($arg)));
throw new RuntimeException(sprintf('"%s::processValue()" must return a Reference when processing an expression, %s returned for service("%s").', \get_class($this), \is_object($arg) ? \get_class($arg) : \gettype($arg), $id));
}
$arg = sprintf('"%s"', $arg);
}
Expand Down

0 comments on commit d5e3f2f

Please sign in to comment.