Skip to content

Commit 245dbac

Browse files
authored
Merge pull request #2397 from Kobzol/do-not-react-to-own-comments
Do not react to the bot's own comments
2 parents 46198ae + 405f57a commit 245dbac

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

site/src/request_handlers/github.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,11 @@ async fn handle_issue(
5656
issue: github::Issue,
5757
comment: github::Comment,
5858
) -> ServerResult<github::Response> {
59+
// Do not react to our own comments, to avoid funny loops :)
60+
if comment.user.login == "rust-timer" {
61+
return Ok(github::Response);
62+
}
63+
5964
let gh_client = client::Client::from_ctxt(&ctxt, RUST_REPO_GITHUB_API_URL.to_owned());
6065
if comment.body.contains(" homu: ") {
6166
if let Some(sha) = parse_homu_comment(&comment.body).await {

0 commit comments

Comments
 (0)