mirror of
https://github.com/TwiN/gatus.git
synced 2024-12-14 11:58:04 +00:00
Ignore "unexpected end of JSON input" errors
This commit is contained in:
parent
8fd6eddc16
commit
a66cfc094a
1 changed files with 3 additions and 1 deletions
|
@ -138,7 +138,9 @@ func sanitizeAndResolve(list []string, result *Result) []string {
|
|||
}
|
||||
resolvedElement, resolvedElementLength, err := jsonpath.Eval(strings.Replace(element, fmt.Sprintf("%s.", BodyPlaceHolder), "", 1), result.Body)
|
||||
if err != nil {
|
||||
if err.Error() != "unexpected end of JSON input" {
|
||||
result.Errors = append(result.Errors, err.Error())
|
||||
}
|
||||
element = fmt.Sprintf("%s %s", element, InvalidConditionElementSuffix)
|
||||
} else {
|
||||
if wantLength {
|
||||
|
|
Loading…
Reference in a new issue