diff --git a/src/display/api.js b/src/display/api.js index 6cc2daa5f..ff7a6aaa3 100644 --- a/src/display/api.js +++ b/src/display/api.js @@ -1168,8 +1168,7 @@ class PDFPageProxy { pageIndex: this._pageIndex, intent: renderingIntent, renderInteractiveForms: renderInteractiveForms === true, - annotationStorage: - (annotationStorage && annotationStorage.getAll()) || null, + annotationStorage: annotationStorage?.getAll() || null, }); } @@ -2551,8 +2550,7 @@ class WorkerTransport { return this.messageHandler .sendWithPromise("SaveDocument", { numPages: this._numPages, - annotationStorage: - (annotationStorage && annotationStorage.getAll()) || null, + annotationStorage: annotationStorage?.getAll() || null, filename: this._fullReader ? this._fullReader.filename : null, }) .finally(() => {