From 8396a0deeb697613f48ded629270a3bc5ce792fc Mon Sep 17 00:00:00 2001 From: Mikeal Rogers Date: Mon, 9 Sep 2019 23:02:03 +0000 Subject: [PATCH] fix: hash missmatch error --- merge-release-run.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/merge-release-run.js b/merge-release-run.js index bb865a7..3232b63 100644 --- a/merge-release-run.js +++ b/merge-release-run.js @@ -28,8 +28,12 @@ const run = async () => { if (latest) { if (latest.gitHead === process.env.GITHUB_SHA) return console.log('SHA matches latest release, skipping.') if (latest.gitHead) { - let logs = await getlog({ from: latest.gitHead, to: process.env.GITHUB_SHA }) - messages = logs.all.map(r => r.message + '\n' + r.body) + try { + let logs = await getlog({ from: latest.gitHead, to: process.env.GITHUB_SHA }) + messages = logs.all.map(r => r.message + '\n' + r.body) + } catch (e) { + latest = null + } // g.log({from: 'f0002b6c9710f818b9385aafeb1bde994fe3b370', to: '53a92ca2d1ea3c55977f44d93e48e31e37d0bc69'}, (err, l) => console.log(l.all.map(r => r.message + '\n' + r.body))) } else { latest = null