Skip to content

Commit

Permalink
chore(actions): Mege body comments
Browse files Browse the repository at this point in the history
  • Loading branch information
1ilsang committed Jun 10, 2024
1 parent 87a23ba commit 6b8a7b7
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/actions/netlify-preview/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,19 +73,20 @@ runs:
return;
}
const prevActionBot = await getExistPrevActionBot(issueNumber);
const body = `Preview URL: ${process.env.NETLIFY_PREVIEW_URL}`;
if (prevActionBot?.id) {
await github.rest.issues.updateComment({
owner,
repo,
comment_id: prevActionBot.id,
body: `Preview URL: ${process.env.NETLIFY_PREVIEW_URL}`
body
});
} else {
await github.rest.issues.createComment({
owner,
repo,
issue_number: issueNumber,
body: `Preview URL: ${process.env.NETLIFY_PREVIEW_URL}`
body
});
}
}
Expand Down

0 comments on commit 6b8a7b7

Please sign in to comment.