Skip to content

Commit e06e959

Browse files
committed
fix: Allow reactions to be added to an existing comment without providing message
Skip issues.updateComment call if no message was provided.
1 parent bc14ce3 commit e06e959

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

src/main.ts

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -93,12 +93,14 @@ async function run() {
9393
comment_id: number;
9494
body: string;
9595
}) {
96-
const { data: comment } = await octokit.rest.issues.updateComment({
97-
owner,
98-
repo,
99-
comment_id,
100-
body,
101-
});
96+
if (body) {
97+
const { data: comment } = await octokit.rest.issues.updateComment({
98+
owner,
99+
repo,
100+
comment_id,
101+
body,
102+
});
103+
}
102104

103105
core.setOutput('id', comment.id);
104106
core.setOutput('body', comment.body);

0 commit comments

Comments
 (0)