Skip to content

Commit

Permalink
Clear event queue
Browse files Browse the repository at this point in the history
  • Loading branch information
penalosa committed Dec 11, 2023
1 parent 1c2bd93 commit eb58f0f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/wrangler/src/sentry/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ export const makeSentry10Transport = (options: BaseTransportOptions) => {

try {
if (sentryReportingAllowed) {
for (const event of eventQueue) {
const eventsToSend = [...eventQueue];
eventQueue = [];
for (const event of eventsToSend) {
await fetch(event[0], event[1]);
}

Expand Down

0 comments on commit eb58f0f

Please sign in to comment.