diff --git a/controllers/manageMrEvent/utils/commenter.ts b/controllers/manageMrEvent/utils/commenter.ts index cfcec64..b3e916e 100644 --- a/controllers/manageMrEvent/utils/commenter.ts +++ b/controllers/manageMrEvent/utils/commenter.ts @@ -156,7 +156,10 @@ ${summarizedMr} | 文件路径 | 变更摘要 | | --- | --- | ${[...summarizedFileMap] - .map(([path, summary]) => `| \`${shortenPath(path)}\` | ${summary} |`) + .map( + ([path, summary]) => + `| \`${shortenPath(path)}\` | ${summary.replaceAll("|", "\\|")} |` + ) .join("\n")} ` this.logger.debug(`Summarized comment: ${summarizedComment}`) diff --git a/package.json b/package.json index 9b7a8bc..8a75867 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "module": "index.ts", "type": "module", "scripts": { - "start": "bun run index.ts", + "start": "NODE_ENV=production bun run index.ts", "dev": "NODE_ENV=dev bun run index.ts --watch", "lint": "eslint --fix .", "prepare": "husky", diff --git a/test/manageMrEvent.test.ts b/test/manageMrEvent.test.ts index 912d253..8496fa5 100644 --- a/test/manageMrEvent.test.ts +++ b/test/manageMrEvent.test.ts @@ -18,7 +18,7 @@ test("manageMrEvent", async () => { id: 139032, }, object_attributes: { - iid: 502, + iid: 505, state: "opened", }, }