Fix the remaining Promise.resolve(undefined) cases

Many years ago now there were some `Promise` implementations that had issues resolving with an *implicitly* `undefined` value. That should no longer be the case, and we've not been using the `Promise.resolve(undefined)` format for a long time, hence this patch fixes the few remaining cases.
This commit is contained in:
Jonas Jenwald 2021-10-03 15:32:33 +02:00
parent a37bc609e8
commit cd22c31752
2 changed files with 2 additions and 2 deletions

View File

@ -831,7 +831,7 @@ class PDFPageView {
renderTask.promise.then(
function () {
showCanvas();
renderCapability.resolve(undefined);
renderCapability.resolve();
},
function (error) {
showCanvas();

View File

@ -278,7 +278,7 @@ class PDFThumbnailView {
draw() {
if (this.renderingState !== RenderingStates.INITIAL) {
console.error("Must be in new state before drawing");
return Promise.resolve(undefined);
return Promise.resolve();
}
const { pdfPage } = this;