comparison vendor/symfony/http-kernel/DependencyInjection/LazyLoadingFragmentHandler.php @ 17:129ea1e6d783

Update, including to Drupal core 8.6.10
author Chris Cannam
date Thu, 28 Feb 2019 13:21:36 +0000
parents 1fec387a4317
children
comparison
equal deleted inserted replaced
16:c2387f117808 17:129ea1e6d783
24 { 24 {
25 private $container; 25 private $container;
26 /** 26 /**
27 * @deprecated since version 3.3, to be removed in 4.0 27 * @deprecated since version 3.3, to be removed in 4.0
28 */ 28 */
29 private $rendererIds = array(); 29 private $rendererIds = [];
30 private $initialized = array(); 30 private $initialized = [];
31 31
32 /** 32 /**
33 * @param ContainerInterface $container A container 33 * @param ContainerInterface $container A container
34 * @param RequestStack $requestStack The Request stack that controls the lifecycle of requests 34 * @param RequestStack $requestStack The Request stack that controls the lifecycle of requests
35 * @param bool $debug Whether the debug mode is enabled or not 35 * @param bool $debug Whether the debug mode is enabled or not
36 */ 36 */
37 public function __construct(ContainerInterface $container, RequestStack $requestStack, $debug = false) 37 public function __construct(ContainerInterface $container, RequestStack $requestStack, $debug = false)
38 { 38 {
39 $this->container = $container; 39 $this->container = $container;
40 40
41 parent::__construct($requestStack, array(), $debug); 41 parent::__construct($requestStack, [], $debug);
42 } 42 }
43 43
44 /** 44 /**
45 * Adds a service as a fragment renderer. 45 * Adds a service as a fragment renderer.
46 * 46 *
57 } 57 }
58 58
59 /** 59 /**
60 * {@inheritdoc} 60 * {@inheritdoc}
61 */ 61 */
62 public function render($uri, $renderer = 'inline', array $options = array()) 62 public function render($uri, $renderer = 'inline', array $options = [])
63 { 63 {
64 // BC 3.x, to be removed in 4.0 64 // BC 3.x, to be removed in 4.0
65 if (isset($this->rendererIds[$renderer])) { 65 if (isset($this->rendererIds[$renderer])) {
66 $this->addRenderer($this->container->get($this->rendererIds[$renderer])); 66 $this->addRenderer($this->container->get($this->rendererIds[$renderer]));
67 unset($this->rendererIds[$renderer]); 67 unset($this->rendererIds[$renderer]);