Ensure loadApiError is caught

And add a better error message.

By using `void` instead of `await`, any error thrown is not caught
by surrounding try-catch blocks.

I could continue to use `void` and explicitly handle any thrown errors
by using `.catch`, but most likely the time savings is minimal and
this makes the code more complex.
This commit is contained in:
Andrew Eisenberg
2022-01-21 10:04:08 -08:00
parent 0dabead789
commit 752ae5743f
6 changed files with 38 additions and 16 deletions

View File

@@ -143,9 +143,10 @@ async function run() {
repositoryNwo,
logger
);
void featureFlags.preloadFeatureFlags();
try {
await featureFlags.preloadFeatureFlags();
const workflowErrors = await validateWorkflow();
if (