From c9159a8876d542f6bb8b4ed8115bc82f82556ec9 Mon Sep 17 00:00:00 2001 From: Richard Zink Date: Wed, 7 Oct 2026 20:38:49 +0200 Subject: [PATCH] Fix clouds3d: temporal dead zone on 's' variable loadImageTexture(s.gl, ...) referenced 's' before its 'var s = canvas.__state' declaration later in the function. Used canvas.__state.gl directly since __state was just assigned. --- vendor/clouds3d.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vendor/clouds3d.js b/vendor/clouds3d.js index 2ab8768..7d857d3 100644 --- a/vendor/clouds3d.js +++ b/vendor/clouds3d.js @@ -311,7 +311,7 @@ window.clouds3dRender = function(target) { // frames render normally before it loads — the shader just // samples a black texture in the meantime. canvas.__groundReady = false; - loadImageTexture(s.gl, 'ground.jpg').then(function(tex) { + loadImageTexture(canvas.__state.gl, 'ground.jpg').then(function(tex) { canvas.__ground = tex; canvas.__groundReady = true; }).catch(function(err) {