Return HTTP 200 even on error to prevent Gitlab from disabling the WH automatically

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
Maxime “pep” Buquet 2023-06-01 16:29:30 +02:00
parent fd96e86f80
commit 9bd430af4b
Signed by: pep
GPG key ID: DEDA74AEECA9D0F2

View file

@ -29,7 +29,7 @@ fn error_res<E: std::fmt::Debug>(e: E) -> Result<Response<Body>, Infallible> {
let text = format!("{:?}", e); let text = format!("{:?}", e);
let res = Response::builder() let res = Response::builder()
.status(400) .status(200)
.body(Body::from(Vec::from(text.as_bytes()))) .body(Body::from(Vec::from(text.as_bytes())))
.unwrap(); .unwrap();
Ok(res) Ok(res)