Rename webhook to hook where appropriate

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
Maxime “pep” Buquet 2024-07-10 14:02:35 +02:00
commit 1cf93d1ba8
No known key found for this signature in database
GPG key ID: DEDA74AEECA9D0F2
4 changed files with 16 additions and 16 deletions

View file

@ -18,13 +18,13 @@
mod bot;
mod error;
mod hook;
mod web;
mod webhook;
use crate::bot::XmppClient;
use crate::error::Error;
use crate::web::webhooks;
use crate::webhook::Hook;
use crate::hook::Hook;
use crate::web::hooks;
use std::fs::File;
use std::io::{Error as IoError, ErrorKind as IoErrorKind, Read};
@ -158,7 +158,7 @@ async fn main() -> Result<!, Error> {
.serve_connection(io, service_fn(|request| {
let value_tx = value_tx.clone();
async move {
webhooks(request, token, value_tx).await
hooks(request, token, value_tx).await
}
}))
.await
@ -170,7 +170,7 @@ async fn main() -> Result<!, Error> {
}
wh = value_rx.recv() => {
if let Some(Hook::Gitlab(hook)) = wh {
client.webhook(hook).await
client.hook(hook).await
}
}
}