This commit is contained in:
James Cole
2017-03-01 21:02:47 +01:00
parent d3a2bf174d
commit dd1e9ecb32

View File

@@ -58,9 +58,11 @@ class Import extends Command
{
Log::debug('Start start-import command');
$jobKey = $this->argument('key');
$job = ImportJob::whereKey($jobKey)->first();
$job = ImportJob::where('key', $jobKey)->first();
if (is_null($job)) {
$this->error(sprintf('No job found with key "%s"', $jobKey));
return;
}
if (!$this->isValid($job)) {
Log::error('Job is not valid for some reason. Exit.');