浏览代码

webhook添加debug log (#8)

LoGin 1 年之前
父节点
当前提交
a43f16585c
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3 0
      src/lib.rs

+ 3 - 0
src/lib.rs

@@ -8,6 +8,7 @@ use crate::github::PullRequestDetails;
 use anyhow::Context;
 use handlers::HandlerError;
 use interactions::ErrorComment;
+use log::debug;
 use serde::Serialize;
 use std::fmt;
 use tracing as log;
@@ -174,6 +175,8 @@ pub async fn webhook(
     payload: String,
     ctx: &handlers::Context,
 ) -> Result<bool, WebhookError> {
+    debug!("{event} event payload: {:?}", payload);
+
     let event = match event {
         EventName::PullRequestReview => {
             let mut payload = deserialize_payload::<github::PullRequestReviewEvent>(&payload)