Skip to content

Commit 1189d92

Browse files
committed
chore(sniff): Refine PHPCodeSniffer configuration.
Also fix the PHP code by applying the sniff rules.
1 parent de35d3f commit 1189d92

File tree

6 files changed

+20
-19
lines changed

6 files changed

+20
-19
lines changed

.php_cs

Lines changed: 0 additions & 13 deletions
This file was deleted.

.php_cs.dist

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
2+
<?php
3+
4+
$finder = PhpCsFixer\Finder::create()
5+
->exclude('vendor')
6+
->in(__DIR__)
7+
;
8+
9+
return PhpCsFixer\Config::create()
10+
->setRules([
11+
'@Symfony' => true,
12+
'array_syntax' => ['syntax' => 'short'],
13+
])
14+
->setFinder($finder);

src/Client.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
namespace Http\Adapter\React;
44

5-
use Http\Client\HttpClient;
65
use Http\Client\HttpAsyncClient;
6+
use Http\Client\HttpClient;
77
use Psr\Http\Message\RequestInterface;
88
use Psr\Http\Message\ResponseInterface;
99
use React\EventLoop\LoopInterface;

src/ReactFactory.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
namespace Http\Adapter\React;
44

5-
use React\EventLoop\LoopInterface;
65
use React\EventLoop\Factory as EventLoopFactory;
6+
use React\EventLoop\LoopInterface;
77
use React\Http\Browser;
88
use React\Socket\ConnectorInterface;
99

@@ -25,8 +25,8 @@ public static function buildEventLoop(): LoopInterface
2525
/**
2626
* Build a React Http Client.
2727
*
28-
* @param ConnectorInterface|null $connector Only pass this argument if you need to customize DNS
29-
* behaviour.
28+
* @param ConnectorInterface|null $connector only pass this argument if you need to customize DNS
29+
* behaviour
3030
*/
3131
public static function buildHttpClient(
3232
LoopInterface $loop,

tests/AsyncClientTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
namespace Http\Adapter\React\Tests;
44

5-
use Http\Client\Tests\HttpAsyncClientTest;
65
use Http\Adapter\React\Client;
76
use Http\Client\HttpAsyncClient;
7+
use Http\Client\Tests\HttpAsyncClientTest;
88

99
/**
1010
* @author Stéphane Hulard <[email protected]>

tests/ClientTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
namespace Http\Adapter\React\Tests;
44

5-
use Http\Client\Tests\HttpClientTest;
65
use Http\Adapter\React\Client;
6+
use Http\Client\Tests\HttpClientTest;
77
use Psr\Http\Client\ClientInterface;
88

99
/**

0 commit comments

Comments
 (0)