Skip to content

Commit fa0ade0

Browse files
tools(deps-dev): Update friendsofphp/php-cs-fixer requirement from 3.16.0 to 3.17.0 in /tools/php-cs-fixer (#302)
* tools(deps-dev): Update friendsofphp/php-cs-fixer requirement Updates the requirements on [friendsofphp/php-cs-fixer](https://github.com/PHP-CS-Fixer/PHP-CS-Fixer) to permit the latest version. - [Release notes](https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/releases) - [Changelog](https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/blob/master/CHANGELOG.md) - [Commits](PHP-CS-Fixer/PHP-CS-Fixer@v3.16.0...v3.17.0) --- updated-dependencies: - dependency-name: friendsofphp/php-cs-fixer dependency-type: direct:development ... Signed-off-by: dependabot[bot] <[email protected]> * apply cs-fixes Signed-off-by: Jan Kowalleck <[email protected]> --------- Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: Jan Kowalleck <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jan Kowalleck <[email protected]>
1 parent 917c978 commit fa0ade0

File tree

9 files changed

+8
-16
lines changed

9 files changed

+8
-16
lines changed

src/Core/Models/BomRef.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ final class BomRef
3838
/** @psalm-var non-empty-string|null */
3939
private ?string $value;
4040

41-
public function __construct(?string $value = null)
41+
public function __construct(string $value = null)
4242
{
4343
$this->setValue($value);
4444
}

src/Core/Serialization/BaseSerializer.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -82,11 +82,9 @@ private function normalize(BOM $bom)
8282
}
8383

8484
/**
85-
* {@inheritDoc}
86-
*
8785
* @SuppressWarnings(PHPMD.BooleanArgumentFlag)
8886
*/
89-
final public function serialize(Bom $bom, ?bool $prettyPrint = null): string
87+
final public function serialize(Bom $bom, bool $prettyPrint = null): string
9088
{
9189
return $this->realSerialize(
9290
$this->normalize($bom),

src/Core/Serialization/DOM/Normalizers/BomNormalizer.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,8 @@ public function normalize(Bom $bom): DOMElement
7575
private function normalizeSerialNumber(?string $serialNumber): ?string
7676
{
7777
// @TODO have the regex configurable per Spec
78-
return \is_string($serialNumber) &&
79-
1 === preg_match('/^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$|^\\{[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\\}$/', $serialNumber)
78+
return \is_string($serialNumber)
79+
&& 1 === preg_match('/^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$|^\\{[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\\}$/', $serialNumber)
8080
? $serialNumber
8181
: null;
8282
}

src/Core/Serialization/JSON/Normalizers/BomNormalizer.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,8 @@ public function normalize(Bom $bom): array
8181
private function normalizeSerialNumber(?string $serialNumber): ?string
8282
{
8383
// @TODO have the regex configurable per Spec
84-
return \is_string($serialNumber) &&
85-
1 === preg_match('/^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/', $serialNumber)
84+
return \is_string($serialNumber)
85+
&& 1 === preg_match('/^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/', $serialNumber)
8686
? $serialNumber
8787
: null;
8888
}

src/Core/Serialization/Serializer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,5 +41,5 @@ interface Serializer
4141
*
4242
* @SuppressWarnings(PHPMD.BooleanArgumentFlag)
4343
*/
44-
public function serialize(Bom $bom, ?bool $prettyPrint = null): string;
44+
public function serialize(Bom $bom, bool $prettyPrint = null): string;
4545
}

src/Core/Validation/Validators/JsonStrictValidator.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,6 @@
3232
class JsonStrictValidator extends JsonValidator
3333
{
3434
/**
35-
* {@inheritdoc}
36-
*
3735
* @internal
3836
*/
3937
protected static function listSchemaFiles(): array

src/Core/Validation/Validators/JsonValidator.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,6 @@
4040
class JsonValidator extends BaseValidator
4141
{
4242
/**
43-
* {@inheritdoc}
44-
*
4543
* @internal as this function may be affected by breaking changes without notice
4644
*/
4745
protected static function listSchemaFiles(): array

src/Core/Validation/Validators/XmlValidator.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,6 @@
3838
class XmlValidator extends BaseValidator
3939
{
4040
/**
41-
* {@inheritdoc}
42-
*
4341
* @internal as this function may be affected by breaking changes without notice
4442
*/
4543
protected static function listSchemaFiles(): array

tools/php-cs-fixer/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"description": "php-cs-fixer",
44
"type": "metapackage",
55
"require-dev": {
6-
"friendsofphp/php-cs-fixer": "3.16.0",
6+
"friendsofphp/php-cs-fixer": "3.17.0",
77
"roave/security-advisories": "dev-latest"
88
},
99
"prefer-stable": true,

0 commit comments

Comments
 (0)