Skip to content

Commit eee13f0

Browse files
committed
Fix code-style
1 parent 6f5fe07 commit eee13f0

32 files changed

+315
-354
lines changed

composer.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@
5454
],
5555
"analyze": [
5656
"@cs",
57-
"vendor/bin/ecs check-markdown README.md --ansi",
5857
"@phpstan"
5958
],
6059
"cs": "vendor/bin/ecs check --ansi",

src/Exception/BadMethodCallException.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,4 @@
22

33
namespace MF\Collection\Exception;
44

5-
class BadMethodCallException extends \BadMethodCallException implements CollectionExceptionInterface
6-
{
7-
}
5+
class BadMethodCallException extends \BadMethodCallException implements CollectionExceptionInterface {}

src/Exception/CollectionExceptionInterface.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,4 @@
22

33
namespace MF\Collection\Exception;
44

5-
interface CollectionExceptionInterface extends \Throwable
6-
{
7-
}
5+
interface CollectionExceptionInterface extends \Throwable {}

src/Exception/InvalidArgumentException.php

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,18 @@
66

77
class InvalidArgumentException extends \InvalidArgumentException implements CollectionExceptionInterface, AssertionFailedException
88
{
9+
/** @phpstan-param mixed[] $constraints */
10+
public function __construct(
11+
string $message,
12+
?int $code = null,
13+
private ?string $propertyPath = null,
14+
private mixed $value = null,
15+
private array $constraints = [],
16+
?\Throwable $previous = null,
17+
) {
18+
parent::__construct($message, (int) $code, $previous);
19+
}
20+
921
public static function forFailedAssertion(AssertionFailedException $e): self
1022
{
1123
return new static(
@@ -18,18 +30,6 @@ public static function forFailedAssertion(AssertionFailedException $e): self
1830
);
1931
}
2032

21-
/** @phpstan-param mixed[] $constraints */
22-
public function __construct(
23-
string $message,
24-
int $code = null,
25-
private ?string $propertyPath = null,
26-
private mixed $value = null,
27-
private array $constraints = [],
28-
\Throwable $previous = null,
29-
) {
30-
parent::__construct($message, (int) $code, $previous);
31-
}
32-
3333
public function getPropertyPath(): ?string
3434
{
3535
return $this->propertyPath;

src/Exception/LogicException.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,4 @@
22

33
namespace MF\Collection\Exception;
44

5-
class LogicException extends \LogicException implements CollectionExceptionInterface
6-
{
7-
}
5+
class LogicException extends \LogicException implements CollectionExceptionInterface {}

src/Exception/OutOfBoundsException.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,4 @@
22

33
namespace MF\Collection\Exception;
44

5-
class OutOfBoundsException extends \OutOfBoundsException implements CollectionExceptionInterface
6-
{
7-
}
5+
class OutOfBoundsException extends \OutOfBoundsException implements CollectionExceptionInterface {}

src/Exception/OutOfRangeException.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,4 @@
22

33
namespace MF\Collection\Exception;
44

5-
class OutOfRangeException extends \OutOfRangeException implements CollectionExceptionInterface
6-
{
7-
}
5+
class OutOfRangeException extends \OutOfRangeException implements CollectionExceptionInterface {}

src/Exception/TupleException.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,4 @@
22

33
namespace MF\Collection\Exception;
44

5-
class TupleException extends InvalidArgumentException implements TupleExceptionInterface
6-
{
7-
}
5+
class TupleException extends InvalidArgumentException implements TupleExceptionInterface {}

src/Exception/TupleExceptionInterface.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,4 @@
22

33
namespace MF\Collection\Exception;
44

5-
interface TupleExceptionInterface extends CollectionExceptionInterface
6-
{
7-
}
5+
interface TupleExceptionInterface extends CollectionExceptionInterface {}

src/Exception/TupleParseException.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,4 @@
22

33
namespace MF\Collection\Exception;
44

5-
class TupleParseException extends TupleException
6-
{
7-
}
5+
class TupleParseException extends TupleException {}

0 commit comments

Comments
 (0)