worker: fix error status codes

The DNFDepsolveError and DNFMarking error should have
a `4xx` code instead of a `5xx` error code.
This commit is contained in:
Gianluca Zuccarelli 2022-02-04 11:06:40 +00:00 committed by Sanne Raymaekers
parent 290472dfdf
commit 1e443cf0fa

View file

@ -52,9 +52,9 @@ func GetStatusCode(err *Error) StatusCode {
}
switch err.ID {
case ErrorDNFDepsolveError:
return JobStatusInternalError
return JobStatusUserInputError
case ErrorDNFMarkingError:
return JobStatusInternalError
return JobStatusUserInputError
case ErrorNoDynamicArgs:
return JobStatusUserInputError
case ErrorInvalidTargetConfig: