returning error object

This commit is contained in:
Wolfgang Hottgenroth 2021-12-02 09:47:48 +01:00
parent a3c1bc99d8
commit fe9c431999
Signed by: wn
GPG Key ID: E49AF3B9EF6DD469

@ -118,7 +118,12 @@ null#slurp
#end if
);
} catch (NotDataFoundException) {
return StatusCode(404, "No $operation['resultType']['apiName'] element found");
var err = new ErrorResultObject();
err.errorCode = 400;
err.serviceErrorCode = 517;
err.errorMessage("item not found");
err.errorInfoURL("https://google.com");
return BadRequest(err);
}
}