Skip to content

Commit 140a567

Browse files
Stop requiring full commit SHA to be provided to bot
Since we query the GitHub API for the commit to learn parents, the full commit hash isn't necessary. It's possibly we'll need more error handling later for invalid commits and so on but for now this should be sufficient to make it much easier to invoke the bot.
1 parent f2d67e0 commit 140a567

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

site/src/server.rs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -549,14 +549,6 @@ pub fn handle_github(request: github::Request, data: &InputData) -> ServerResult
549549
if let Some(captures) = BODY_TRY_COMMIT.captures(&body) {
550550
if let Some(commit) = captures.get(1).map(|c| c.as_str()) {
551551
let commit = commit.trim_start_matches("https://github.com/rust-lang/rust/commit/");
552-
if commit.len() != 40 {
553-
post_comment(
554-
&data.config,
555-
&request.issue,
556-
"Please provide the full 40 character commit hash.",
557-
)?;
558-
return Ok(github::Response);
559-
}
560552
let client = reqwest::Client::new();
561553
let commit_response: github::Commit = client
562554
.get(&format!(

0 commit comments

Comments
 (0)