TypeError fCallback not a function

This commit is contained in:
the-djmaze 2022-09-02 12:11:47 +02:00
parent 732b6eb641
commit 3553bfa2d9

View file

@ -162,7 +162,7 @@ export class AbstractFetchRemote
}
}
fCallback?.(
fCallback && fCallback(
iError,
data,
cached,
@ -173,7 +173,7 @@ export class AbstractFetchRemote
)
.catch(err => {
console.error({fetchError:err});
fCallback?.(
fCallback && fCallback(
'TimeoutError' == err.reason ? 3 : (err.name == 'AbortError' ? 2 : 1),
err
);