mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Alerting: Recact html responses (#35277)
This commit is contained in:
parent
8cda1f5153
commit
fba90b8f9b
@ -118,6 +118,10 @@ func (p *AlertingProxy) withReq(
|
||||
errMessage = message.(string)
|
||||
}
|
||||
}
|
||||
} else if strings.HasPrefix(resp.Header().Get("Content-Type"), "text/html") {
|
||||
// if Content-Type is text/html
|
||||
// do not return the body
|
||||
errMessage = "redacted html"
|
||||
}
|
||||
return ErrResp(status, errors.New(errMessage), "")
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user