allocation_limit), DisplayException::class, 'You cannot delete allocations for this server: no allocation limit is set.'); throw_if($allocation->id === $server->allocation_id, DisplayException::class, 'You cannot delete the primary allocation for this server.'); Allocation::query()->where('id', $allocation->id)->update([ 'notes' => null, 'server_id' => null, ]); return $allocation->refresh(); } }