[dev] Mute flood wait error alerts (#6138)
This commit is contained in:
parent
322b0defc0
commit
c0dbdc35a0
@ -44,11 +44,18 @@ export function handleError(err: Error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function handleErrorEvent(e: ErrorEvent | PromiseRejectionEvent) {
|
function handleErrorEvent(e: ErrorEvent | PromiseRejectionEvent) {
|
||||||
|
if (e instanceof ErrorEvent) {
|
||||||
// https://stackoverflow.com/questions/49384120/resizeobserver-loop-limit-exceeded
|
// https://stackoverflow.com/questions/49384120/resizeobserver-loop-limit-exceeded
|
||||||
if (e instanceof ErrorEvent && e.message === 'ResizeObserver loop limit exceeded') {
|
if (e.message === 'ResizeObserver loop limit exceeded') {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Flood wait errors
|
||||||
|
if (e.message.includes('A wait of')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
handleError(e instanceof ErrorEvent ? (e.error || e.message) : e.reason);
|
handleError(e instanceof ErrorEvent ? (e.error || e.message) : e.reason);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user