From c3b6340fa0edbb5e807dbc0eaf74d15a47de5a40 Mon Sep 17 00:00:00 2001 From: James Joffe Date: Sat, 6 Jul 2024 17:31:42 +1000 Subject: [PATCH] fix formatting --- src/Listeners/ReverbMessageReceivedListener.php | 2 +- src/LivewireBeacon.php | 6 +++--- src/LivewireBeaconServiceProvider.php | 2 +- tests/TestCase.php | 3 +-- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/Listeners/ReverbMessageReceivedListener.php b/src/Listeners/ReverbMessageReceivedListener.php index 0a305dd..c55e61a 100644 --- a/src/Listeners/ReverbMessageReceivedListener.php +++ b/src/Listeners/ReverbMessageReceivedListener.php @@ -21,7 +21,7 @@ public function __construct() public function handle(MessageReceived $event): void { $message = json_decode($event->message, associative: true); - if (!isset($message['event']) || $message['event'] !== config('livewire-beacon.events.inbound')) { + if (! isset($message['event']) || $message['event'] !== config('livewire-beacon.events.inbound')) { return; } diff --git a/src/LivewireBeacon.php b/src/LivewireBeacon.php index eb23732..f63fd41 100755 --- a/src/LivewireBeacon.php +++ b/src/LivewireBeacon.php @@ -10,7 +10,7 @@ class LivewireBeacon public static function livewireBeaconScripts($expression) { - return '{!! \Executable\LivewireBeacon\LivewireBeacon::scripts(' . $expression . ') !!}'; + return '{!! \Executable\LivewireBeacon\LivewireBeacon::scripts('.$expression.') !!}'; } public static function scripts($options = []) @@ -29,8 +29,8 @@ public function returnJavascriptAsFile() { return Utils::pretendResponseIsFile( config('app.debug') - ? __DIR__ . '/../dist/beacon.js' - : __DIR__ . '/../dist/beacon.min.js' + ? __DIR__.'/../dist/beacon.js' + : __DIR__.'/../dist/beacon.min.js' ); } } diff --git a/src/LivewireBeaconServiceProvider.php b/src/LivewireBeaconServiceProvider.php index eb8ff26..b2123f4 100644 --- a/src/LivewireBeaconServiceProvider.php +++ b/src/LivewireBeaconServiceProvider.php @@ -39,7 +39,7 @@ public function packageBooted() ); $url = $route->uri(); - $url = (string) str($url)->when(!str($url)->isUrl(), fn ($url) => $url->start('/')); + $url = (string) str($url)->when(! str($url)->isUrl(), fn ($url) => $url->start('/')); LivewireBeacon::$javascriptRoute = $url; } diff --git a/tests/TestCase.php b/tests/TestCase.php index ef09e08..4bb526b 100644 --- a/tests/TestCase.php +++ b/tests/TestCase.php @@ -2,9 +2,8 @@ namespace Executable\LivewireBeacon\Tests; -use Illuminate\Database\Eloquent\Factories\Factory; -use Orchestra\Testbench\TestCase as Orchestra; use Executable\LivewireBeacon\LivewireBeaconServiceProvider; +use Orchestra\Testbench\TestCase as Orchestra; class TestCase extends Orchestra {