Form GitlabHook payloads again
Don't check for the secret validity at this point Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
parent
407788af5a
commit
6903490ace
1 changed files with 1 additions and 3 deletions
|
@ -81,9 +81,7 @@ async fn hooks_inner(req: Request<Incoming>, secret: &str) -> Result<Hook, Error
|
|||
|
||||
let hook: ForgejoHook = serde_json::from_slice(&payload[..])?;
|
||||
return Ok(Hook::Forgejo(hook));
|
||||
} else if let Some(val) = headers.get("X-Gitlab-Token")
|
||||
&& secret != val
|
||||
{
|
||||
} else if let Some(val) = headers.get("X-Gitlab-Token") {
|
||||
if secret != val {
|
||||
return Err(Error::InvalidSecret);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue