only abort lock if action matches badactions

This commit is contained in:
Oliver Gorwits
2017-05-23 16:11:29 +01:00
parent 415559b24f
commit b51edbccd2
2 changed files with 1 additions and 7 deletions

View File

@@ -151,7 +151,7 @@ sub jq_lock {
backend => $fqdn, device => $job->device,
},{ key => 'device_skip_pkey' })->add_to_actionset(@badactions);
return false;
return false if scalar grep {$_ eq $job->action} @badactions;
}
# lock db row and update to show job has been picked