diff --git a/Command/ConfigDebugCommand.php b/Command/ConfigDebugCommand.php index 758c605ec..6aa3fbf9b 100644 --- a/Command/ConfigDebugCommand.php +++ b/Command/ConfigDebugCommand.php @@ -139,7 +139,7 @@ private function getConfigForPath(array $config, $path, $alias) $steps = explode('.', $path); foreach ($steps as $step) { - if (!array_key_exists($step, $config)) { + if (!\array_key_exists($step, $config)) { throw new LogicException(sprintf('Unable to find configuration for "%s.%s"', $alias, $path)); } diff --git a/Console/Descriptor/JsonDescriptor.php b/Console/Descriptor/JsonDescriptor.php index 83f607cc3..6b05612ff 100644 --- a/Console/Descriptor/JsonDescriptor.php +++ b/Console/Descriptor/JsonDescriptor.php @@ -156,7 +156,7 @@ protected function describeContainerAlias(Alias $alias, array $options = [], Con */ protected function describeEventDispatcherListeners(EventDispatcherInterface $eventDispatcher, array $options = []) { - $this->writeData($this->getEventDispatcherListenersData($eventDispatcher, array_key_exists('event', $options) ? $options['event'] : null), $options); + $this->writeData($this->getEventDispatcherListenersData($eventDispatcher, \array_key_exists('event', $options) ? $options['event'] : null), $options); } /** diff --git a/Console/Descriptor/MarkdownDescriptor.php b/Console/Descriptor/MarkdownDescriptor.php index a0a0dc851..6575b05ec 100644 --- a/Console/Descriptor/MarkdownDescriptor.php +++ b/Console/Descriptor/MarkdownDescriptor.php @@ -275,7 +275,7 @@ protected function describeContainerParameter($parameter, array $options = []) */ protected function describeEventDispatcherListeners(EventDispatcherInterface $eventDispatcher, array $options = []) { - $event = array_key_exists('event', $options) ? $options['event'] : null; + $event = \array_key_exists('event', $options) ? $options['event'] : null; $title = 'Registered listeners'; if (null !== $event) { diff --git a/Console/Descriptor/TextDescriptor.php b/Console/Descriptor/TextDescriptor.php index 7aed45bd4..90c760260 100644 --- a/Console/Descriptor/TextDescriptor.php +++ b/Console/Descriptor/TextDescriptor.php @@ -385,7 +385,7 @@ protected function describeContainerParameter($parameter, array $options = []) */ protected function describeEventDispatcherListeners(EventDispatcherInterface $eventDispatcher, array $options = []) { - $event = array_key_exists('event', $options) ? $options['event'] : null; + $event = \array_key_exists('event', $options) ? $options['event'] : null; if (null !== $event) { $title = sprintf('Registered Listeners for "%s" Event', $event); diff --git a/Console/Descriptor/XmlDescriptor.php b/Console/Descriptor/XmlDescriptor.php index 38efe8575..53e2ee1fa 100644 --- a/Console/Descriptor/XmlDescriptor.php +++ b/Console/Descriptor/XmlDescriptor.php @@ -111,7 +111,7 @@ protected function describeContainerAlias(Alias $alias, array $options = [], Con */ protected function describeEventDispatcherListeners(EventDispatcherInterface $eventDispatcher, array $options = []) { - $this->writeDocument($this->getEventDispatcherListenersDocument($eventDispatcher, array_key_exists('event', $options) ? $options['event'] : null)); + $this->writeDocument($this->getEventDispatcherListenersDocument($eventDispatcher, \array_key_exists('event', $options) ? $options['event'] : null)); } /** diff --git a/DependencyInjection/Configuration.php b/DependencyInjection/Configuration.php index f49c5f11e..52c770645 100644 --- a/DependencyInjection/Configuration.php +++ b/DependencyInjection/Configuration.php @@ -371,7 +371,7 @@ private function addWorkflowSection(ArrayNodeDefinition $rootNode) } foreach ($transitions as $name => $transition) { - if (array_key_exists('name', $transition)) { + if (\array_key_exists('name', $transition)) { continue; } $transition['name'] = $name; diff --git a/DependencyInjection/FrameworkExtension.php b/DependencyInjection/FrameworkExtension.php index a46e552a2..ee5dc86df 100644 --- a/DependencyInjection/FrameworkExtension.php +++ b/DependencyInjection/FrameworkExtension.php @@ -602,7 +602,7 @@ private function registerWorkflowConfiguration(array $config, ContainerBuilder $ $registryDefinition = $container->getDefinition('workflow.registry'); foreach ($config['workflows'] as $name => $workflow) { - if (!array_key_exists('type', $workflow)) { + if (!\array_key_exists('type', $workflow)) { $workflow['type'] = 'workflow'; @trigger_error(sprintf('The "type" option of the "framework.workflows.%s" configuration entry must be defined since Symfony 3.3. The default value will be "state_machine" in Symfony 4.0.', $name), E_USER_DEPRECATED); } @@ -1052,7 +1052,7 @@ private function registerAssetsConfiguration(array $config, ContainerBuilder $co foreach ($config['packages'] as $name => $package) { if (null !== $package['version_strategy']) { $version = new Reference($package['version_strategy']); - } elseif (!array_key_exists('version', $package) && null === $package['json_manifest_path']) { + } elseif (!\array_key_exists('version', $package) && null === $package['json_manifest_path']) { // if neither version nor json_manifest_path are specified, use the default $version = $defaultVersion; } else { @@ -1273,7 +1273,7 @@ private function registerValidationConfiguration(array $config, ContainerBuilder $definition = $container->findDefinition('validator.email'); $definition->replaceArgument(0, $config['strict_email']); - if (array_key_exists('enable_annotations', $config) && $config['enable_annotations']) { + if (\array_key_exists('enable_annotations', $config) && $config['enable_annotations']) { if (!$this->annotationsConfigEnabled) { throw new \LogicException('"enable_annotations" on the validator cannot be set as Annotations support is disabled.'); } @@ -1281,7 +1281,7 @@ private function registerValidationConfiguration(array $config, ContainerBuilder $validatorBuilder->addMethodCall('enableAnnotationMapping', [new Reference('annotation_reader')]); } - if (array_key_exists('static_method', $config) && $config['static_method']) { + if (\array_key_exists('static_method', $config) && $config['static_method']) { foreach ($config['static_method'] as $methodName) { $validatorBuilder->addMethodCall('addMethodMapping', [$methodName]); }