Skip to content

Commit bcd1fda

Browse files
committed
perf: simplify promise storage logic in setInFlightPromise function
1 parent 8f5a389 commit bcd1fda

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

src/inflight-manager.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -174,10 +174,8 @@ export function setInFlightPromise(
174174
): void {
175175
const item = inFlight.get(key);
176176
if (item) {
177-
// store the promise at index 4
177+
// store the promise at index 4 — item is already the Map's reference, no need to re-set
178178
item[4] = promise;
179-
180-
inFlight.set(key, item);
181179
}
182180
}
183181

0 commit comments

Comments
 (0)