Skip to content

Commit 75af9ed

Browse files
committed
CS
1 parent 128ef84 commit 75af9ed

File tree

3 files changed

+7
-6
lines changed

3 files changed

+7
-6
lines changed

lib/Imgur/Client.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ public function setHttpClient(HttpClientInterface $httpClient): void
8888
public function getOption(string $name): ?string
8989
{
9090
if (!\array_key_exists($name, $this->options)) {
91-
throw new InvalidArgumentException(sprintf('Undefined option called: "%s"', $name));
91+
throw new InvalidArgumentException(\sprintf('Undefined option called: "%s"', $name));
9292
}
9393

9494
return $this->options[$name];
@@ -100,7 +100,7 @@ public function getOption(string $name): ?string
100100
public function setOption(string $name, ?string $value = null): void
101101
{
102102
if (!\array_key_exists($name, $this->options)) {
103-
throw new InvalidArgumentException(sprintf('Undefined option called: "%s"', $name));
103+
throw new InvalidArgumentException(\sprintf('Undefined option called: "%s"', $name));
104104
}
105105

106106
$this->options[$name] = $value;

lib/Imgur/Exception/MissingArgumentException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ public function __construct($required, int $code = 0)
1313
$required = [$required];
1414
}
1515

16-
parent::__construct(sprintf('One or more of required ("%s") parameters is missing!', implode('", "', $required)), $code);
16+
parent::__construct(\sprintf('One or more of required ("%s") parameters is missing!', implode('", "', $required)), $code);
1717
}
1818
}

phpstan.neon

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@ parameters:
55
- tests
66

77
bootstrapFiles:
8-
- vendor/bin/.phpunit/phpunit-8.5-0/vendor/autoload.php
9-
10-
checkMissingIterableValueType: false
8+
- vendor/bin/.phpunit/phpunit-9.6-0/vendor/autoload.php
119

1210
ignoreErrors:
1311
# because the test is skipped
@@ -17,3 +15,6 @@ parameters:
1715
-
1816
message: '#Unreachable statement#'
1917
path: %currentWorkingDirectory%/tests/Api/ImageTest.php
18+
19+
-
20+
identifier: missingType.iterableValue

0 commit comments

Comments
 (0)