Unit tests for pack service
This commit is contained in:
parent
2e3476298d
commit
b2ec9960a1
5 changed files with 718 additions and 1 deletions
|
@ -87,7 +87,7 @@ class PackDeletionService
|
|||
$pack = $this->repository->withColumns(['id', 'uuid'])->find($pack);
|
||||
}
|
||||
|
||||
$count = $this->serverRepository->findCountWhere([['pack_id', '=', $pack]]);
|
||||
$count = $this->serverRepository->findCountWhere([['pack_id', '=', $pack->id]]);
|
||||
if ($count !== 0) {
|
||||
throw new HasActiveServersException(trans('admin/exceptions.packs.delete_has_servers'));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue