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

@@ -3,7 +3,6 @@
namespace App\Http\Livewire\Server;
use App\Models\Server;
use Illuminate\Support\Facades\Storage;
use Livewire\Component;
use Masmerise\Toaster\Toaster;
@@ -13,6 +12,16 @@ class PrivateKey extends Component
public $privateKeys;
public $parameters;
public function setPrivateKey($private_key_id)
{
$this->server->update([
'private_key_id' => $private_key_id
]);
refreshPrivateKey($this->server->privateKey);
$this->server->refresh();
$this->checkConnection();
}
public function checkConnection()
{
try {
@@ -27,15 +36,7 @@ class PrivateKey extends Component
return general_error_handler(customErrorMessage: "Server is not reachable. Reason: {$e->getMessage()}", that: $this);
}
}
public function setPrivateKey($private_key_id)
{
$this->server->update([
'private_key_id' => $private_key_id
]);
refreshPrivateKey($this->server->privateKey);
$this->server->refresh();
$this->checkConnection();
}
public function mount()
{
$this->parameters = getRouteParameters();