From eb0c93d266f52f6890e565028180dd28d78d07fe Mon Sep 17 00:00:00 2001 From: kovacsv Date: Sun, 17 Feb 2019 09:44:21 +0100 Subject: [PATCH] Fix error with invalid mesh index. --- website/include/importerapp.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/website/include/importerapp.js b/website/include/importerapp.js index 94481bc..ef2982c 100644 --- a/website/include/importerapp.js +++ b/website/include/importerapp.js @@ -601,7 +601,10 @@ ImporterApp.prototype.RegisterCanvasClick = function (canvasName) ImporterApp.prototype.ScrollMeshIntoView = function (meshIndex) { - menuItem = this.meshMenuItems[meshIndex]; + if (meshIndex == -1) { + return; + } + var menuItem = this.meshMenuItems[meshIndex]; menuItem.menuItemDiv.get (0).scrollIntoView (); };