Apply fixes from StyleCI (#448)

This commit is contained in:
rennokki 2020-08-13 14:02:58 +03:00 committed by GitHub
parent 8dc28561f9
commit 815eabc801
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 33 additions and 33 deletions

View File

@ -2,13 +2,13 @@
namespace BeyondCode\LaravelWebSockets\HttpApi\Controllers; namespace BeyondCode\LaravelWebSockets\HttpApi\Controllers;
use BeyondCode\LaravelWebSockets\PubSub\ReplicationInterface;
use BeyondCode\LaravelWebSockets\WebSockets\Channels\ChannelManager;
use BeyondCode\LaravelWebSockets\WebSockets\Channels\PresenceChannel;
use Illuminate\Http\Request; use Illuminate\Http\Request;
use Illuminate\Support\Collection; use Illuminate\Support\Collection;
use Illuminate\Support\Str; use Illuminate\Support\Str;
use Symfony\Component\HttpKernel\Exception\HttpException; use Symfony\Component\HttpKernel\Exception\HttpException;
use BeyondCode\LaravelWebSockets\PubSub\ReplicationInterface;
use BeyondCode\LaravelWebSockets\WebSockets\Channels\ChannelManager;
use BeyondCode\LaravelWebSockets\WebSockets\Channels\PresenceChannel;
class FetchChannelsController extends Controller class FetchChannelsController extends Controller
{ {
@ -45,7 +45,7 @@ class FetchChannelsController extends Controller
// We want to get the channel user count all in one shot when // We want to get the channel user count all in one shot when
// using a replication backend rather than doing individual queries. // using a replication backend rather than doing individual queries.
// To do so, we first collect the list of channel names. // To do so, we first collect the list of channel names.
$channelNames = $channels->map(function (PresenceChannel $channel) use ($request) { $channelNames = $channels->map(function (PresenceChannel $channel) {
return $channel->getChannelName(); return $channel->getChannelName();
})->toArray(); })->toArray();

View File

@ -2,12 +2,12 @@
namespace BeyondCode\LaravelWebSockets\PubSub\Broadcasters; namespace BeyondCode\LaravelWebSockets\PubSub\Broadcasters;
use Pusher\Pusher;
use Illuminate\Support\Arr;
use Illuminate\Support\Str;
use Illuminate\Contracts\Redis\Factory as Redis;
use Illuminate\Broadcasting\Broadcasters\Broadcaster; use Illuminate\Broadcasting\Broadcasters\Broadcaster;
use Illuminate\Broadcasting\Broadcasters\UsePusherChannelConventions; use Illuminate\Broadcasting\Broadcasters\UsePusherChannelConventions;
use Illuminate\Contracts\Redis\Factory as Redis;
use Illuminate\Support\Arr;
use Illuminate\Support\Str;
use Pusher\Pusher;
use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException; use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException;
class RedisPusherBroadcaster extends Broadcaster class RedisPusherBroadcaster extends Broadcaster

View File

@ -2,11 +2,11 @@
namespace BeyondCode\LaravelWebSockets\PubSub\Drivers; namespace BeyondCode\LaravelWebSockets\PubSub\Drivers;
use stdClass; use BeyondCode\LaravelWebSockets\PubSub\ReplicationInterface;
use React\EventLoop\LoopInterface; use React\EventLoop\LoopInterface;
use React\Promise\FulfilledPromise; use React\Promise\FulfilledPromise;
use React\Promise\PromiseInterface; use React\Promise\PromiseInterface;
use BeyondCode\LaravelWebSockets\PubSub\ReplicationInterface; use stdClass;
class LocalClient implements ReplicationInterface class LocalClient implements ReplicationInterface
{ {

View File

@ -2,14 +2,14 @@
namespace BeyondCode\LaravelWebSockets\PubSub\Drivers; namespace BeyondCode\LaravelWebSockets\PubSub\Drivers;
use stdClass;
use Illuminate\Support\Str;
use Clue\React\Redis\Client;
use Clue\React\Redis\Factory;
use React\EventLoop\LoopInterface;
use React\Promise\PromiseInterface;
use BeyondCode\LaravelWebSockets\PubSub\ReplicationInterface; use BeyondCode\LaravelWebSockets\PubSub\ReplicationInterface;
use BeyondCode\LaravelWebSockets\WebSockets\Channels\ChannelManager; use BeyondCode\LaravelWebSockets\WebSockets\Channels\ChannelManager;
use Clue\React\Redis\Client;
use Clue\React\Redis\Factory;
use Illuminate\Support\Str;
use React\EventLoop\LoopInterface;
use React\Promise\PromiseInterface;
use stdClass;
class RedisClient implements ReplicationInterface class RedisClient implements ReplicationInterface
{ {

View File

@ -2,9 +2,9 @@
namespace BeyondCode\LaravelWebSockets\PubSub; namespace BeyondCode\LaravelWebSockets\PubSub;
use stdClass;
use React\EventLoop\LoopInterface; use React\EventLoop\LoopInterface;
use React\Promise\PromiseInterface; use React\Promise\PromiseInterface;
use stdClass;
interface ReplicationInterface interface ReplicationInterface
{ {

View File

@ -17,13 +17,13 @@ use BeyondCode\LaravelWebSockets\Statistics\Http\Controllers\WebSocketStatistics
use BeyondCode\LaravelWebSockets\Statistics\Http\Middleware\Authorize as AuthorizeStatistics; use BeyondCode\LaravelWebSockets\Statistics\Http\Middleware\Authorize as AuthorizeStatistics;
use BeyondCode\LaravelWebSockets\WebSockets\Channels\ChannelManager; use BeyondCode\LaravelWebSockets\WebSockets\Channels\ChannelManager;
use BeyondCode\LaravelWebSockets\WebSockets\Channels\ChannelManagers\ArrayChannelManager; use BeyondCode\LaravelWebSockets\WebSockets\Channels\ChannelManagers\ArrayChannelManager;
use Pusher\Pusher;
use Psr\Log\LoggerInterface;
use Illuminate\Broadcasting\BroadcastManager; use Illuminate\Broadcasting\BroadcastManager;
use Illuminate\Support\Facades\Gate; use Illuminate\Support\Facades\Gate;
use Illuminate\Support\Facades\Route; use Illuminate\Support\Facades\Route;
use Illuminate\Support\ServiceProvider;
use Illuminate\Support\Facades\Schema; use Illuminate\Support\Facades\Schema;
use Illuminate\Support\ServiceProvider;
use Psr\Log\LoggerInterface;
use Pusher\Pusher;
class WebSocketsServiceProvider extends ServiceProvider class WebSocketsServiceProvider extends ServiceProvider
{ {

View File

@ -2,9 +2,9 @@
namespace BeyondCode\LaravelWebSockets\Tests; namespace BeyondCode\LaravelWebSockets\Tests;
use Illuminate\Support\Facades\Config;
use BeyondCode\LaravelWebSockets\PubSub\Drivers\LocalClient; use BeyondCode\LaravelWebSockets\PubSub\Drivers\LocalClient;
use BeyondCode\LaravelWebSockets\PubSub\ReplicationInterface; use BeyondCode\LaravelWebSockets\PubSub\ReplicationInterface;
use Illuminate\Support\Facades\Config;
trait TestsReplication trait TestsReplication
{ {