diff --git a/lib/platform/github/index.js b/lib/platform/github/index.js index 285281cc53737366733940ad402103d84f5f6e7a..9471952ce2db933a2d33e49bb421d9f22d3dbc90 100644 --- a/lib/platform/github/index.js +++ b/lib/platform/github/index.js @@ -535,21 +535,30 @@ async function getComments(issueNo) { async function addComment(issueNo, body) { // POST /repos/:owner/:repo/issues/:number/comments - await get.post(`repos/${config.repoName}/issues/${issueNo}/comments`, { - body: { body }, - }); + await get.post( + `repos/${config.parentRepo || config.repoName}/issues/${issueNo}/comments`, + { + body: { body }, + } + ); } async function editComment(commentId, body) { // PATCH /repos/:owner/:repo/issues/comments/:id - await get.patch(`repos/${config.repoName}/issues/comments/${commentId}`, { - body: { body }, - }); + await get.patch( + `repos/${config.parentRepo || + config.repoName}/issues/comments/${commentId}`, + { + body: { body }, + } + ); } async function deleteComment(commentId) { // DELETE /repos/:owner/:repo/issues/comments/:id - await get.delete(`repos/${config.repoName}/issues/comments/${commentId}`); + await get.delete( + `repos/${config.parentRepo || config.repoName}/issues/comments/${commentId}` + ); } async function ensureComment(issueNo, topic, content) {