message: Rewrite limitConcurrency to fix error catching
  Make sure that we only catch errors that are a result of
  calling fn()
diff: @@ -48,30 +48,30 @@ function checkBacklog() {
  // Limit the maximum number of ongoing promises returned by fn to LIMIT and
  // use a FIFO queue to handle the backlog.
  -function limitConcurrency(fn) {
  - return new Promise((resolve, reject) => {
  - const item = () => {
  - ongoingRequestCount++;
  - resolve();
  - };
  +async function limitConcurrency(fn) {
  if (ongoingRequestCount >= LIMIT) {
  // Enqueue this request for later execution
  - backlogQueue.push(item);
  - } else {
  - item();
  + await new Promise((resolve, reject) => {
  + backlogQueue.push(resolve);
  + });
  }
  - })
  - .then(fn)
  - .catch((err) => {
  - ongoingRequestCount--;
  - checkBacklog();
  - throw err;
  - })
  - .then((result) => {
  +
  + let result;
  + let error;
  +
  + ongoingRequestCount++;
  + try {
  + result = await fn();
  + } catch (err) {
  + error = err;
  + } finally {
  ongoingRequestCount--;
  checkBacklog();
  + }
  +
  + if (error) throw error;
  +
  return result;
  - });
  }
  /**
  