Skip to content

Commit 3514c60

Browse files
authored
Merge pull request #74 from Teamwork/fix-comment-formatting
Fix PR title bold formatting and null review comments
2 parents 2992906 + 4a2a41b commit 3514c60

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎src/github.sh‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ github::get_pr_url() {
3333
}
3434

3535
github::get_pr_title() {
36-
jq --raw-output .pull_request.title "$GITHUB_EVENT_PATH"
36+
jq --raw-output '.pull_request.title | trim' "$GITHUB_EVENT_PATH"
3737
}
3838

3939
github::get_pr_patch_stats() {
@@ -53,7 +53,7 @@ github::get_review_state() {
5353
}
5454

5555
github::get_review_comment() {
56-
jq --raw-output .review.body "$GITHUB_EVENT_PATH"
56+
jq --raw-output '.review.body // empty' "$GITHUB_EVENT_PATH"
5757
}
5858

5959
github::print_all_data() {

0 commit comments

Comments
 (0)