Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit d294085

Browse filesBrowse files
bug #34923 [DI] Fix support for immutable setters in CallTrait (Lctrs)
This PR was merged into the 4.3 branch. Discussion ---------- [DI] Fix support for immutable setters in CallTrait | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | yes | Deprecations? | no | Tickets | | License | MIT | Doc PR | N/A Commits ------- 90ace51 [DI] Add support for immutable setters in CallTrait
2 parents ebadf51 + 90ace51 commit d294085
Copy full SHA for d294085

File tree

1 file changed

+5
-4
lines changed
Filter options
  • src/Symfony/Component/DependencyInjection/Loader/Configurator/Traits

1 file changed

+5
-4
lines changed

‎src/Symfony/Component/DependencyInjection/Loader/Configurator/Traits/CallTrait.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/DependencyInjection/Loader/Configurator/Traits/CallTrait.php
+5-4Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,16 +18,17 @@ trait CallTrait
1818
/**
1919
* Adds a method to call after service initialization.
2020
*
21-
* @param string $method The method name to call
22-
* @param array $arguments An array of arguments to pass to the method call
21+
* @param string $method The method name to call
22+
* @param array $arguments An array of arguments to pass to the method call
23+
* @param bool $returnsClone Whether the call returns the service instance or not
2324
*
2425
* @return $this
2526
*
2627
* @throws InvalidArgumentException on empty $method param
2728
*/
28-
final public function call($method, array $arguments = [])
29+
final public function call($method, array $arguments = [], $returnsClone = false)
2930
{
30-
$this->definition->addMethodCall($method, static::processValue($arguments, true));
31+
$this->definition->addMethodCall($method, static::processValue($arguments, true), $returnsClone);
3132

3233
return $this;
3334
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.