diff --git a/lib/App/Netdisco/Worker/Plugin.pm b/lib/App/Netdisco/Worker/Plugin.pm index 44999403..8f05a7c4 100644 --- a/lib/App/Netdisco/Worker/Plugin.pm +++ b/lib/App/Netdisco/Worker/Plugin.pm @@ -74,9 +74,9 @@ register 'register_worker' => sub { push @newuserconf, dclone $stanza; } - # # per-device action but no device creds available - # return $job->add_status( Status->info('skip: driver or action not applicable') ) - # if 0 == scalar @newuserconf; + # per-device action but no device creds available + return $job->add_status( Status->info('skip: driver or action not applicable') ) + if 0 == scalar @newuserconf; } # back up and restore device_auth diff --git a/lib/App/Netdisco/Worker/Runner.pm b/lib/App/Netdisco/Worker/Runner.pm index 4cdbf041..193281ca 100644 --- a/lib/App/Netdisco/Worker/Runner.pm +++ b/lib/App/Netdisco/Worker/Runner.pm @@ -49,9 +49,9 @@ sub run { push @newuserconf, dclone $stanza; } - # # per-device action but no device creds available - # return $job->add_status( Status->defer('deferred job with no device creds') ) - # if 0 == scalar @newuserconf; + # per-device action but no device creds available + return $job->add_status( Status->defer('deferred job with no device creds') ) + if 0 == scalar @newuserconf; } # back up and restore device_auth