Skip to content

Commit 71ce77f

Browse files
Apply php-cs-fixer rule for array_key_exists()
1 parent 6a2ae30 commit 71ce77f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Input/Input.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ public function validate()
6969
$givenArguments = $this->arguments;
7070

7171
$missingArguments = array_filter(array_keys($definition->getArguments()), function ($argument) use ($definition, $givenArguments) {
72-
return !array_key_exists($argument, $givenArguments) && $definition->getArgument($argument)->isRequired();
72+
return !\array_key_exists($argument, $givenArguments) && $definition->getArgument($argument)->isRequired();
7373
});
7474

7575
if (\count($missingArguments) > 0) {
@@ -150,7 +150,7 @@ public function getOption($name)
150150
throw new InvalidArgumentException(sprintf('The "%s" option does not exist.', $name));
151151
}
152152

153-
return array_key_exists($name, $this->options) ? $this->options[$name] : $this->definition->getOption($name)->getDefault();
153+
return \array_key_exists($name, $this->options) ? $this->options[$name] : $this->definition->getOption($name)->getDefault();
154154
}
155155

156156
/**

Tester/ApplicationTester.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public function run(array $input, $options = [])
6666
$this->input->setInteractive($options['interactive']);
6767
}
6868

69-
$this->captureStreamsIndependently = array_key_exists('capture_stderr_separately', $options) && $options['capture_stderr_separately'];
69+
$this->captureStreamsIndependently = \array_key_exists('capture_stderr_separately', $options) && $options['capture_stderr_separately'];
7070
if (!$this->captureStreamsIndependently) {
7171
$this->output = new StreamOutput(fopen('php://memory', 'w', false));
7272
if (isset($options['decorated'])) {

0 commit comments

Comments
 (0)