Skip to content

Commit 145fb1b

Browse files
Avoid attempting to post "finished" if running locally
This is only really a problem when running locally but connecting to the production database, but since that's something that is quite useful for debugging it seems nice to have. An alternative fix might be a read-only credential set for prod.
1 parent d2c387b commit 145fb1b

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

site/src/github.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -582,6 +582,11 @@ where
582582
}
583583

584584
pub async fn post_finished(data: &InputData) {
585+
// If the github token is not configured, do not run this -- we don't want
586+
// to mark things as complete without posting the comment.
587+
if data.config.keys.github.is_none() {
588+
return;
589+
}
585590
let conn = data.conn().await;
586591
let index = data.index.load();
587592
let mut commits = index

0 commit comments

Comments
 (0)