fix(github): don't block forkToken automerge (#9909)

This commit is contained in:
Rhys Arkins 2021-05-07 21:23:46 +02:00 committed by GitHub
parent 825a946468
commit 8445c42590
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -634,6 +634,10 @@ async function getOpenPrs(): Promise<PrList> {
pr.canMergeReason = `hasNegativeReview`;
} else if (canMergeStates.includes(pr.mergeStateStatus)) {
pr.canMerge = true;
} else if (config.forkToken && pr.mergeStateStatus === 'BLOCKED') {
// The main token can't merge but maybe the forking token can
// istanbul ignore next
pr.canMerge = true;
} else {
pr.canMerge = false;
pr.canMergeReason = `mergeStateStatus = ${pr.mergeStateStatus}`;