Skip to content

Commit ff13a27

Browse files
committed
Fix cs
1 parent 5534165 commit ff13a27

File tree

4 files changed

+8
-14
lines changed

4 files changed

+8
-14
lines changed

.cs.php

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,20 +12,15 @@
1212
// custom rules
1313
'align_multiline_comment' => ['comment_type' => 'phpdocs_only'], // psr-5
1414
'phpdoc_to_comment' => false,
15+
'no_superfluous_phpdoc_tags' => false,
1516
'array_indentation' => true,
1617
'array_syntax' => ['syntax' => 'short'],
1718
'cast_spaces' => ['space' => 'none'],
1819
'concat_space' => ['spacing' => 'one'],
1920
'compact_nullable_typehint' => true,
2021
'declare_equal_normalize' => ['space' => 'single'],
21-
'general_phpdoc_annotation_remove' => [
22-
'annotations' => [
23-
'author',
24-
'package',
25-
],
26-
],
2722
'increment_style' => ['style' => 'post'],
28-
'list_syntax' => ['syntax' => 'long'],
23+
'list_syntax' => ['syntax' => 'short'],
2924
'no_short_echo_tag' => true,
3025
'phpdoc_add_missing_param_annotation' => ['only_untyped' => false],
3126
'phpdoc_align' => false,
@@ -39,6 +34,7 @@
3934
'sort_algorithm' => 'alpha',
4035
'imports_order' => ['class', 'const', 'function']
4136
],
37+
'single_line_throw' => false,
4238
])
4339
->setFinder(PhpCsFixer\Finder::create()
4440
->in(__DIR__ . '/src')

src/Encoder/JsonEncoder.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,9 @@ public function encode($data): string
2323
$result = json_encode($data);
2424

2525
if ($result === false) {
26-
throw new UnexpectedValueException(sprintf(
27-
'JSON encoding failed. Code: %s. Error: %s.',
28-
json_last_error(),
29-
json_last_error_msg()
30-
));
26+
throw new UnexpectedValueException(
27+
sprintf('JSON encoding failed. Code: %s. Error: %s.', json_last_error(), json_last_error_msg())
28+
);
3129
}
3230

3331
return $result;

tests/Middleware/MiddlewareTestTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ trait MiddlewareTestTrait
1515
/**
1616
* Run middleware stack.
1717
*
18-
* @param array $queue The queue
18+
* @param array<mixed> $queue The queue
1919
*
2020
* @return ResponseInterface The response
2121
*/

tests/TestService.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class TestService
1717
*
1818
* @throws ValidationException
1919
*
20-
* @return array Result data
20+
* @return array<mixed> Result data
2121
*/
2222
public function process(int $id): array
2323
{

0 commit comments

Comments
 (0)