Skip to content

Commit 40e6a21

Browse files
committed
Fix PSR-12 conformance
1 parent c656a1c commit 40e6a21

65 files changed

Lines changed: 104 additions & 7 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎CHANGELOG.md‎

Lines changed: 1 addition & 1 deletion

‎composer.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
"phpstan/phpstan-phpunit": "^0.11.2",
2626
"phpstan/phpstan-strict-rules": "^0.11.0",
2727
"phpunit/phpunit": "^7.0.0||^8.2.0",
28-
"squizlabs/php_codesniffer": "^3.4.0",
28+
"squizlabs/php_codesniffer": "^3.5.1",
2929
"woohoolabs/coding-standard": "^1.0.0",
3030
"woohoolabs/releaser": "^1.1.0"
3131
},

‎phpcs.xml‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,21 @@
1818
<file>tests/</file>
1919

2020
<rule ref="WoohooLabs"/>
21+
22+
<rule ref="SlevomatCodingStandard.Namespaces.UseSpacing">
23+
<properties>
24+
<property name="linesCountAfterLastUse" value="1"/>
25+
<property name="linesCountBeforeFirstUse" value="1"/>
26+
<property name="linesCountBetweenUseTypes" value="1"/>
27+
</properties>
28+
</rule>
29+
30+
<!-- Require presence of declare(strict_types=1) -->
31+
<rule ref="SlevomatCodingStandard.TypeHints.DeclareStrictTypes">
32+
<properties>
33+
<property name="newlinesCountBetweenOpenTagAndDeclare" value="2"/>
34+
<property name="spacesCountAroundEqualsSign" value="0"/>
35+
<property name="newlinesCountAfterDeclare" value="2"/>
36+
</properties>
37+
</rule>
2138
</ruleset>

‎src/JsonApi/Client/JsonApiAsyncClient.php‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace WoohooLabs\Yang\JsonApi\Client;

‎src/JsonApi/Client/JsonApiClient.php‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace WoohooLabs\Yang\JsonApi\Client;

‎src/JsonApi/Exception/DocumentException.php‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace WoohooLabs\Yang\JsonApi\Exception;

‎src/JsonApi/Exception/JsonApiExceptionInterface.php‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace WoohooLabs\Yang\JsonApi\Exception;

‎src/JsonApi/Exception/ResponseException.php‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace WoohooLabs\Yang\JsonApi\Exception;

‎src/JsonApi/Exception/SerializationException.php‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace WoohooLabs\Yang\JsonApi\Exception;

‎src/JsonApi/Hydrator/AbstractClassDocumentHydrator.php‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
23
declare(strict_types=1);
34

45
namespace WoohooLabs\Yang\JsonApi\Hydrator;

0 commit comments

Comments
 (0)