Skip to content

Commit 1945d37

Browse files
authored
Merge pull request #2164 from Urgau/gh-changes-since-no-body
Handle empty/no body in reviews in `[review-changes-since]` handler
2 parents 5370418 + e4d8fec commit 1945d37

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/handlers/review_changes_since.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ use crate::{
66
handlers::Context,
77
};
88

9-
/// Checks if this event is a PR review creation and adds in the body a link our `gh-changes-since`
10-
/// endpoint to view changes since this review.
9+
/// Checks if this event is a PR review creation and adds in the body (if there is one)
10+
/// a link our `gh-changes-since` endpoint to view changes since this review.
1111
pub(crate) async fn handle(
1212
ctx: &Context,
1313
host: &str,
@@ -29,6 +29,7 @@ pub(crate) async fn handle(
2929
..
3030
},
3131
) = event
32+
&& !event.comment.body.is_empty()
3233
{
3334
// Add link our gh-changes-since endpoint to view changes since this review
3435

0 commit comments

Comments
 (0)