fix: reset error modal state in Proxmox Firewall component to ensure proper user feedback during error handling
This commit is contained in:
@@ -88,6 +88,7 @@ class Firewall extends Component
|
||||
$data = $response->json()['data'] ?? [];
|
||||
$this->firewallEnabled = isset($data['enable']) && $data['enable'] == 1;
|
||||
$this->error = '';
|
||||
$this->showErrorModal = false;
|
||||
} catch (\Exception $e) {
|
||||
$errorMessage = $e->getMessage();
|
||||
// Try to extract more detailed error from response if available
|
||||
@@ -165,6 +166,7 @@ class Firewall extends Component
|
||||
$data = $response->json()['data'] ?? [];
|
||||
$this->rules = is_array($data) ? $data : [];
|
||||
$this->error = '';
|
||||
$this->showErrorModal = false;
|
||||
} catch (\Exception $e) {
|
||||
$errorMessage = $e->getMessage();
|
||||
// Try to extract more detailed error from response if available
|
||||
|
||||
Reference in New Issue
Block a user