refactor(events): remove ProxyStarted event and associated ProxyStartedNotification listener for code cleanup

This commit is contained in:
Andras Bacsai
2025-06-10 10:54:23 +02:00
parent 81d6cb539b
commit b4dd5cb21b
2 changed files with 0 additions and 38 deletions

View File

@@ -1,14 +0,0 @@
<?php
namespace App\Events;
use Illuminate\Broadcasting\InteractsWithSockets;
use Illuminate\Foundation\Events\Dispatchable;
use Illuminate\Queue\SerializesModels;
class ProxyStarted
{
use Dispatchable, InteractsWithSockets, SerializesModels;
public function __construct(public $data) {}
}

View File

@@ -1,24 +0,0 @@
<?php
namespace App\Listeners;
use App\Events\ProxyStarted;
use App\Events\ProxyStatusChanged;
use App\Models\Server;
class ProxyStartedNotification
{
public Server $server;
public function __construct() {}
public function handle(ProxyStarted $event): void
{
$this->server = data_get($event, 'data');
$this->server->setupDefaultRedirect();
$this->server->setupDynamicProxyConfiguration();
$this->server->proxy->force_stop = false;
$this->server->save();
// ProxyStatusChanged::dispatch( $this->server->id);
}
}