Explorar o código

Docs: Refactor URL generation in geometry browser. (#23087)

* Limit LGTM errors

* Update geometry-browser.html

Co-authored-by: Michael Herzog <[email protected]>
gero3 %!s(int64=3) %!d(string=hai) anos
pai
achega
5169da8792
Modificáronse 1 ficheiros con 7 adicións e 1 borrados
  1. 7 1
      docs/scenes/geometry-browser.html

+ 7 - 1
docs/scenes/geometry-browser.html

@@ -696,8 +696,14 @@
 			}
 
 			//
+			
+			const selectedGeometry = window.location.hash.substring( 1 );
 
-			document.getElementById( 'newWindow' ).href += window.location.hash;
+			if ( guis[ selectedGeometry ] !== undefined ) {
+
+				document.getElementById( 'newWindow' ).href += window.location.hash;
+
+			}
 
 			const gui = new GUI();