Don't go to pages that don't exist

This commit is contained in:
Ray Schamp 2015-05-07 17:06:58 -04:00
parent 30e6bb0828
commit 505e23beac

View file

@ -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();