mirror of
https://github.com/scratchfoundation/scratchx.git
synced 2024-11-28 18:45:49 -05:00
Don't go to pages that don't exist
This commit is contained in:
parent
30e6bb0828
commit
505e23beac
1 changed files with 2 additions and 0 deletions
|
@ -320,6 +320,8 @@ function showPage(path) {
|
|||
var toShow = "#" + path;
|
||||
var $toShow = $(toShow);
|
||||
|
||||
if (!$toShow.length) return;
|
||||
|
||||
$(toHide).filter(":visible").hide();
|
||||
if (toShow != "#editor") $("#editor").css({top: "-9999px"});
|
||||
$("body > main, body > main > article").has($toShow).show();
|
||||
|
|
Loading…
Reference in a new issue