diff --git a/lib/platform/github/index.ts b/lib/platform/github/index.ts index 5a1a47f5d2877162281c36e3228aa6f58a846755..3ad40973f2287b9af37a42c56acb80a757761249 100644 --- a/lib/platform/github/index.ts +++ b/lib/platform/github/index.ts @@ -1552,9 +1552,7 @@ export async function ensureComment({ if (err.message === PLATFORM_FAILURE) { throw err; } - if ( - err.message === 'Unable to create comment because issue is locked. (403)' - ) { + if (err.body?.message?.includes('is locked')) { logger.debug('Issue is locked - cannot add comment'); } else { logger.warn({ err }, 'Error ensuring comment');