Code for Spectre.

This commit is contained in:
James Cole
2018-05-16 21:31:45 +02:00
parent 9f26757e8a
commit dd44a1e517
3 changed files with 15 additions and 3 deletions

View File

@@ -114,7 +114,7 @@ class JobStatusController extends Controller
public function start(ImportJob $importJob): JsonResponse
{
// catch impossible status:
$allowed = ['ready_to_run', 'need_job_config'];
$allowed = ['ready_to_run', 'need_job_config','error']; // todo remove error
if (null !== $importJob && !\in_array($importJob->status, $allowed, true)) {
Log::error('Job is not ready.');