fix(limits): Re-throw ExternalHostError on calling getBranchPr (#17721)

This commit is contained in:
Sergei Zharinov 2022-09-09 15:01:31 +03:00 committed by GitHub
parent cbc78e30fd
commit 049d624be9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -60,9 +60,14 @@ export async function getConcurrentPrsRemaining(
openPrs.push(pr); openPrs.push(pr);
} }
} catch (err) { } catch (err) {
// istanbul ignore if
if (err instanceof ExternalHostError) {
throw err;
} else {
// no-op // no-op
} }
} }
}
logger.debug(`${openPrs.length} PRs are currently open`); logger.debug(`${openPrs.length} PRs are currently open`);
const concurrentRemaining = Math.max( const concurrentRemaining = Math.max(
0, 0,