Show fallback bar on unhandled rejections
This commit is contained in:
parent
ce218d021f
commit
23ea9d879d
@ -748,7 +748,7 @@ var Promise = PDFJS.Promise = (function PromiseClosure() {
|
|||||||
var now = Date.now();
|
var now = Date.now();
|
||||||
for (var i = 0; i < this.unhandledRejections.length; i++) {
|
for (var i = 0; i < this.unhandledRejections.length; i++) {
|
||||||
if (now - this.unhandledRejections[i].time > REJECTION_TIMEOUT) {
|
if (now - this.unhandledRejections[i].time > REJECTION_TIMEOUT) {
|
||||||
console.error('Unhandled rejection: ' +
|
warn('Unhandled rejection: ' +
|
||||||
this.unhandledRejections[i].promise._value);
|
this.unhandledRejections[i].promise._value);
|
||||||
this.unhandledRejections.splice(i);
|
this.unhandledRejections.splice(i);
|
||||||
i--;
|
i--;
|
||||||
|
Loading…
Reference in New Issue
Block a user