wretch-middlewares icon indicating copy to clipboard operation
wretch-middlewares copied to clipboard

throttlingCache: TypeError ?(src/throttlingCache/index) error undefined is not an object (evaluating 'x.get(r).forEach')

Open vigzmv opened this issue 4 years ago • 0 comments

This has been a recurring error on our site, on latest browser version. Couldn't reproduce myself yet. Reporting here for the record, I will see if I can fix this

                return response
            })
            .catch(error => {
                // Reject pending promises on error
                inflight.get(_key).forEach(([resolve, reject]) => reject(error))  <--- HERE
                inflight.delete(_key)
                throw error
            })
    }

vigzmv avatar May 05 '20 15:05 vigzmv