fix(sentinel): Add missing instantSave method and prevent duplicate notifications (#7749)

This commit is contained in:
Andras Bacsai
2025-12-23 15:36:30 +01:00
committed by GitHub
+10 -20
View File
@@ -110,26 +110,6 @@ class Sentinel extends Component
}
}
public function updatedIsSentinelDebugEnabled($value)
{
try {
$this->submit();
$this->restartSentinel();
} catch (\Throwable $e) {
return handleError($e, $this);
}
}
public function updatedIsMetricsEnabled($value)
{
try {
$this->submit();
$this->restartSentinel();
} catch (\Throwable $e) {
return handleError($e, $this);
}
}
public function updatedIsSentinelEnabled($value)
{
try {
@@ -175,6 +155,16 @@ class Sentinel extends Component
}
}
public function instantSave()
{
try {
$this->syncData(true);
$this->restartSentinel();
} catch (\Throwable $e) {
return handleError($e, $this);
}
}
public function render()
{
return view('livewire.server.sentinel');