修复 无法删除的 bug
This commit is contained in:
parent
852dbcb50e
commit
ac0b0da416
@ -131,15 +131,13 @@ public function destroy($host)
|
||||
if ($host instanceof Host) {
|
||||
$host->delete();
|
||||
} else {
|
||||
$host = Host::where('id', $host)->first($host);
|
||||
$host = Host::findOrFail($host);
|
||||
|
||||
if ($host) {
|
||||
$host->delete();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
return $this->deleted($host);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user