Enable specifying a domain for nodelist import, and throwing exceptions when errors occur

This commit is contained in:
Deon George
2022-11-05 10:35:41 +11:00
parent c7187dbb0e
commit 531654724a
2 changed files with 13 additions and 8 deletions

View File

@@ -16,6 +16,7 @@ class NodelistImport extends Command
*/
protected $signature = 'nodelist:import'
.' {file : File ID}'
.' {domain? : Domain Name}'
.' {--D|delete : Delete old data for the date}'
.' {--U|unlink : Delete file after import}';
@@ -33,6 +34,6 @@ class NodelistImport extends Command
*/
public function handle()
{
return Job::dispatchSync(File::findOrFail($this->argument('file')),$this->option('delete'),$this->option('unlink'));
return Job::dispatchSync(File::findOrFail($this->argument('file')),$this->argument('domain'),$this->option('delete'),$this->option('unlink'));
}
}