Skip to content

Commit b124017

Browse files
Merge pull request #122 from ctrf-io/fix/marker
fix: add marker after all updates
2 parents d112d19 + e942482 commit b124017

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

dist/index.js

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/github/handler.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -115,10 +115,6 @@ async function handleComment(
115115
}
116116
): Promise<void> {
117117
let finalBody = body
118-
if (!finalBody.includes(marker)) {
119-
finalBody = `${finalBody}\n${marker}`
120-
}
121-
122118
const existingComment = await findExistingMarkedComment(
123119
owner,
124120
repo,
@@ -134,6 +130,10 @@ async function handleComment(
134130
}
135131
}
136132

133+
if (!finalBody.includes(marker)) {
134+
finalBody = `${finalBody}\n${marker}`
135+
}
136+
137137
if (
138138
existingComment &&
139139
(updateConfig.shouldUpdate || updateConfig.shouldOverwrite)

0 commit comments

Comments
 (0)