Skip to content

Commit

Permalink
dispatch an error message
Browse files Browse the repository at this point in the history
  • Loading branch information
peaklabs-dev committed Nov 14, 2024
1 parent 465dfbd commit b18d4b9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/Livewire/Server/Show.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,8 @@ public function syncData(bool $toModel = false)
->where('id', '!=', $this->server->id)
->exists()) {
$this->ip = $this->server->ip;
throw new \Exception('This IP/Domain is already in use by another server in your team.');

return $this->dispatch('error', 'This IP/Domain is already in use by another server in your team.');
}

$this->server->name = $this->name;
Expand Down

0 comments on commit b18d4b9

Please sign in to comment.