From 1ee2558b23490efec117f2a3b94a970e5c9ebb89 Mon Sep 17 00:00:00 2001 From: Avindra Goolcharan Date: Fri, 4 Dec 2020 22:33:07 -0500 Subject: wasm/js: fix invalid restartCount reference MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The `restartCount` variable on line 245 is mutating global scope. The PR makes it consistent with the rest ob the code (`self.restartCount`). It was observed when importing the qtloader in a typical Webpack/Babel build environment. Change-Id: I338285f4f6bcb80df0c16d80cc3ebfec944a8be7 Reviewed-by: Morten Johan Sørvig --- src/plugins/platforms/wasm/qtloader.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/plugins') diff --git a/src/plugins/platforms/wasm/qtloader.js b/src/plugins/platforms/wasm/qtloader.js index ef4a6ec2b9..b159cd63ab 100644 --- a/src/plugins/platforms/wasm/qtloader.js +++ b/src/plugins/platforms/wasm/qtloader.js @@ -242,7 +242,7 @@ function QtLoader(config) publicAPI.setFontDpi = setFontDpi; publicAPI.fontDpi = fontDpi; - restartCount = 0; + self.restartCount = 0; function fetchResource(filePath) { var fullPath = config.path + filePath; -- cgit v1.2.3