argument('type'); if (! class_exists($class)) abort(500,sprintf('No class [%s]',$this->argument('type'))); foreach ($class::where('filename','LIKE','%INCOMING%')->get() as $o) { if ($o->scanned AND ! $o->duplicate AND ! $o->remove AND ($x=$o->moveable()) === TRUE) { $this->warn(sprintf('Ignoring [%s], it is not readable',$o->file_path())); continue; } switch (strtolower($this->argument('type'))) { case 'video': $this->dispatch((new VideoMove($o))->onQueue('move')); break; } } } }