@@ 172-179 (lines=8) @@ | ||
169 | } |
|
170 | ||
171 | // Validate the Pack |
|
172 | if (! isset($data['pack_id']) || (int) $data['pack_id'] < 1) { |
|
173 | $data['pack_id'] = null; |
|
174 | } else { |
|
175 | $pack = Pack::where('id', $data['pack_id'])->where('option_id', $data['option_id'])->first(); |
|
176 | if (! $pack) { |
|
177 | throw new DisplayException('The requested service pack does not seem to exist for this combination.'); |
|
178 | } |
|
179 | } |
|
180 | ||
181 | // Load up the Service Information |
|
182 | $service = Service::find($option->service_id); |
|
@@ 818-825 (lines=8) @@ | ||
815 | } |
|
816 | ||
817 | // Validate the Pack |
|
818 | if (! isset($data['pack_id']) || (int) $data['pack_id'] < 1) { |
|
819 | $data['pack_id'] = null; |
|
820 | } else { |
|
821 | $pack = Pack::where('id', $data['pack_id'])->where('option_id', $data['option_id'])->first(); |
|
822 | if (! $pack) { |
|
823 | throw new DisplayException('The requested service pack does not seem to exist for this combination.'); |
|
824 | } |
|
825 | } |
|
826 | ||
827 | return DB::transaction(function () use ($admin, $data, $server) { |
|
828 | $server->installed = 0; |