From 6167adbb8c5707d9758f3d21f9cadc1dc2ea785c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 26 Jun 2021 07:19:30 +0000 Subject: [PATCH 1/2] Update doctrine/coding-standard requirement from ^8.2 to ^8.2 || ^9.0 Updates the requirements on [doctrine/coding-standard](https://github.com/doctrine/coding-standard) to permit the latest version. - [Release notes](https://github.com/doctrine/coding-standard/releases) - [Commits](https://github.com/doctrine/coding-standard/compare/8.2.0...9.0.0) --- updated-dependencies: - dependency-name: doctrine/coding-standard dependency-type: direct:development ... Signed-off-by: dependabot[bot] --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index e8be65a..911e110 100644 --- a/composer.json +++ b/composer.json @@ -18,7 +18,7 @@ "webonyx/graphql-php": "^14.0" }, "require-dev": { - "doctrine/coding-standard": "^8.2", + "doctrine/coding-standard": "^9.0", "infection/infection": "^0.23.0", "phpstan/extension-installer": "^1.1", "phpstan/phpstan": "0.12.90", From 20db4951e903b52031717b68779a52514991100b Mon Sep 17 00:00:00 2001 From: Simon Podlipsky Date: Sat, 26 Jun 2021 10:21:56 +0300 Subject: [PATCH 2/2] Fix CS --- src/Exception/InvalidArgument.php | 4 +--- src/Type/DateTimeType.php | 14 +++----------- 2 files changed, 4 insertions(+), 14 deletions(-) diff --git a/src/Exception/InvalidArgument.php b/src/Exception/InvalidArgument.php index ca13ab4..ff5fe9f 100644 --- a/src/Exception/InvalidArgument.php +++ b/src/Exception/InvalidArgument.php @@ -23,9 +23,7 @@ public static function invalidNameFormat(string $invalidName): self return new self(sprintf('Name "%s" does not match pattern "%s"', $invalidName, TypeBuilder::VALID_NAME_PATTERN)); } - /** - * @param mixed $invalidValue - */ + /** @param mixed $invalidValue */ public static function valueNotIso8601Compliant($invalidValue): self { return new self(sprintf('DateTime type expects input value to be ISO 8601 compliant. Given invalid value "%s"', (string) $invalidValue)); diff --git a/src/Type/DateTimeType.php b/src/Type/DateTimeType.php index 8c202fb..3deff47 100644 --- a/src/Type/DateTimeType.php +++ b/src/Type/DateTimeType.php @@ -48,9 +48,7 @@ public function __construct() ); } - /** - * @param mixed $value - */ + /** @param mixed $value */ public function serialize($value): string { if (! $value instanceof DateTimeInterface) { @@ -62,9 +60,7 @@ public function serialize($value): string return $value->format(DateTimeInterface::ATOM); } - /** - * @param mixed $value - */ + /** @param mixed $value */ public function parseValue($value): DateTimeImmutable { if (! is_string($value)) { @@ -78,11 +74,7 @@ public function parseValue($value): DateTimeImmutable return new DateTimeImmutable($value); } - /** - * @param mixed[]|null $variables - * - * @phpcsSuppress SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingNativeTypeHint - */ + /** @param mixed[]|null $variables */ public function parseLiteral(Node $valueNode, ?array $variables = null): ?DateTimeImmutable { if (! $valueNode instanceof StringValueNode) {