Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
adonesky1 committed Oct 21, 2024
1 parent 27fd6fe commit d67e1ce
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ export class QueuedRequestController extends BaseController<
this.#requestQueue
.filter(({ origin }) => origin === flushOrigin)
.forEach(({ processRequest }) => {
this.#processingRequestCount -= 1;
// this.#processingRequestCount -= 1;
processRequest(
new Error(
'The request has been rejected due to a change in selected network. Please verify the selected network and retry the request.',
Expand All @@ -250,8 +250,7 @@ export class QueuedRequestController extends BaseController<
this.#requestQueue = this.#requestQueue.filter(
({ origin }) => origin !== flushOrigin,
);
this.#originOfCurrentBatch = undefined;
this.#networkClientIdOfCurrentBatch = undefined;
this.#processingRequestCount = 0;
}

/**
Expand Down Expand Up @@ -411,7 +410,9 @@ export class QueuedRequestController extends BaseController<
try {
await requestNext();
} finally {
this.#processingRequestCount -= 1;
if (this.#processingRequestCount > 0) {
this.#processingRequestCount -= 1;
}
}
return undefined;
} finally {
Expand Down

0 comments on commit d67e1ce

Please sign in to comment.