testing php storm code cleanup and styling

This commit is contained in:
Andras Bacsai
2023-08-08 11:51:36 +02:00
parent a8ee779b31
commit f2228cec7b
368 changed files with 23834 additions and 2623 deletions

View File

@@ -5,7 +5,6 @@ namespace App\Http\Livewire\Server;
use App\Actions\Proxy\CheckConfigurationSync;
use App\Actions\Proxy\SaveConfigurationSync;
use App\Enums\ProxyTypes;
use Illuminate\Support\Str;
use App\Models\Server;
use Livewire\Component;
@@ -17,21 +16,25 @@ class Proxy extends Component
public $proxy_settings = null;
public string|null $redirect_url = null;
protected $listeners = ['proxyStatusUpdated', 'saveConfiguration'=>'submit'];
protected $listeners = ['proxyStatusUpdated', 'saveConfiguration' => 'submit'];
public function mount()
{
$this->redirect_url = $this->server->proxy->redirect_url;
}
public function proxyStatusUpdated()
{
$this->server->refresh();
}
public function change_proxy()
{
$this->server->proxy = null;
$this->server->save();
$this->emit('proxyStatusUpdated');
}
public function select_proxy(string $proxy_type)
{
$this->server->proxy->type = $proxy_type;
@@ -39,6 +42,7 @@ class Proxy extends Component
$this->server->save();
$this->emit('proxyStatusUpdated');
}
public function submit()
{
try {
@@ -53,6 +57,7 @@ class Proxy extends Component
return general_error_handler(err: $e);
}
}
public function reset_proxy_configuration()
{
try {
@@ -61,6 +66,7 @@ class Proxy extends Component
return general_error_handler(err: $e);
}
}
public function load_proxy_configuration()
{
try {
@@ -69,4 +75,4 @@ class Proxy extends Component
return general_error_handler(err: $e);
}
}
}
}