From 3a5aaac8c2f4314a7d09d026fc86ccbc23845dca Mon Sep 17 00:00:00 2001 From: m-schuetz Date: Mon, 21 Jun 2021 18:34:32 +0200 Subject: [PATCH] fix bug when unfocusing from 360 image and clicking anywhere but a 360 sphere, which then breaks 360. --- src/modules/Images360/Images360.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/Images360/Images360.js b/src/modules/Images360/Images360.js index 0572913e..02026fd0 100644 --- a/src/modules/Images360/Images360.js +++ b/src/modules/Images360/Images360.js @@ -75,7 +75,7 @@ export class Images360 extends EventDispatcher{ viewer.inputHandler.addInputListener(this); this.addEventListener("mousedown", () => { - if(currentlyHovered){ + if(currentlyHovered && currentlyHovered.image360){ this.focus(currentlyHovered.image360); } });