Skip to content

Commit

Permalink
Update pr-filter.js to correct error
Browse files Browse the repository at this point in the history
  • Loading branch information
mohatagarvit authored Nov 4, 2024
1 parent 83275ea commit 3fd2ea4
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/scripts/pr-filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,12 @@ function hasDescription(markdown) {
module.exports = async ({ github, context, core }) => {
const pr = context.payload.pull_request;
const body = pr.body === null ? '' : pr.body;
const markdown = body.replace(/<!--[\s\S]*?-->/g, '');
let previous;
let markdown = body;
do {
previous = markdown;
markdown = markdown.replace(/<!--[\s\S]*?-->/g, '');
} while (markdown !== previous);
const action = context.payload.action;

const isValid =
Expand Down

0 comments on commit 3fd2ea4

Please sign in to comment.