|
|
@@ -67,10 +67,8 @@ this.singlefile = this.singlefile || {
|
|
|
options.insertSingleFileComment = true;
|
|
|
options.insertCanonicalLink = true;
|
|
|
options.onprogress = event => {
|
|
|
- if (event.type === event.RESOURCES_INITIALIZED) {
|
|
|
- if (options.loadDeferredImages) {
|
|
|
- this.processors.lazy.content.loader.resetZoomLevel(options);
|
|
|
- }
|
|
|
+ if (event.type === event.RESOURCES_INITIALIZED && doc && window && options.loadDeferredImages) {
|
|
|
+ this.processors.lazy.content.loader.resetZoomLevel(options);
|
|
|
}
|
|
|
};
|
|
|
const processor = new this.SingleFile(options);
|