Skip to content

Commit ad6075b

Browse files
authored
Update definitions.rst
Rename the returned variable from setArgument method and the assigned variable to addArgument method
1 parent 735f543 commit ad6075b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

service_container/definitions.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,10 +92,10 @@ fetched from the container::
9292
9393
// adds a new argument with the name of the argument
9494
// $argumentName = the name of the argument in the constructor
95-
$argument = $definition->setArgument('$argumentName', $argumentValue);
95+
$definition = $definition->setArgument('$argumentName', $argumentValue);
9696

9797
// adds a new argument
98-
$definition->addArgument($argument);
98+
$definition->addArgument($argumentValue);
9999

100100
// replaces argument on a specific index (0 = first argument)
101101
$definition->replaceArgument($index, $argument);

0 commit comments

Comments
 (0)