From 7302d83f60bc7dfdd65266c12e8041b1ace12504 Mon Sep 17 00:00:00 2001 From: asmsuechan Date: Sun, 9 Jul 2017 18:08:33 +0900 Subject: [PATCH] Fix a bug on click event --- browser/main/index.js | 1 + 1 file changed, 1 insertion(+) diff --git a/browser/main/index.js b/browser/main/index.js index c8a72e9c..07774fa6 100644 --- a/browser/main/index.js +++ b/browser/main/index.js @@ -24,6 +24,7 @@ document.addEventListener('dragover', function (e) { }) document.addEventListener('click', function (e) { + if (!e.target.className) return const isInfoButton = e.target.className.includes('infoButton') const isInfoPanel = e.target.offsetParent.className.includes('infoPanel') if (isInfoButton || isInfoPanel) return