2024-05-31 07:37:40 +01:00
|
|
|
//
|
|
|
|
use crate as github;
|
|
|
|
use git_next_config as config;
|
|
|
|
use git_next_git as git;
|
|
|
|
|
|
|
|
pub fn parse_body(
|
2024-06-19 07:03:08 +01:00
|
|
|
body: &config::webhook::forge_notification::Body,
|
2024-05-31 07:37:40 +01:00
|
|
|
) -> git::forge::webhook::Result<config::webhook::push::Push> {
|
|
|
|
serde_json::from_str::<github::webhook::Push>(body.as_str())?.try_into()
|
|
|
|
}
|