From 3aab61fd2abe5f9d0109e6dafb21929a5b1d90bb Mon Sep 17 00:00:00 2001 From: Matthew Petroff Date: Sat, 17 Dec 2022 21:16:19 -0500 Subject: [PATCH] Avoid race condition between `updateOnce()` and `setUpdate(true)`. --- src/js/pannellum.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/js/pannellum.js b/src/js/pannellum.js index 5b49ab0..b25482d 100644 --- a/src/js/pannellum.js +++ b/src/js/pannellum.js @@ -3058,6 +3058,7 @@ this.getRenderer = function() { this.setUpdate = function(bool) { update = bool === true; if (update) { + updateOnce = false; if (renderer === undefined) onImageLoad(); else