From 4e92446a14b2d9380ec68103cd15e0c3155baf8d Mon Sep 17 00:00:00 2001 From: coderaiser Date: Thu, 23 Aug 2018 18:02:18 +0300 Subject: [PATCH] fix(listeners) isNoCurrent: can not go to root when root is empty --- client/listeners/index.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/client/listeners/index.js b/client/listeners/index.js index ba38e5a7..85bb0e2d 100644 --- a/client/listeners/index.js +++ b/client/listeners/index.js @@ -168,6 +168,10 @@ function getPathListener(panel) { function isNoCurrent(panel) { const infoPanel = Info.panel; + + if (!infoPanel) + return true; + const namePanel = panel.getAttribute('data-name'); const nameInfoPanel = infoPanel.getAttribute('data-name');