fix broken history navigation

This commit is contained in:
zadam 2019-04-22 17:13:24 +02:00
parent 983d9c4319
commit 15eaf67189

View file

@ -792,8 +792,9 @@ utils.bindShortcut('ctrl+.', scrollToActiveNote);
$(window).bind('hashchange', async function() {
if (isNotePathInAddress()) {
const notePath = getHashValueFromAddress();
const noteId = notePath.split("/").pop();
if (notePath !== '-' && await getActiveNotePath() !== notePath) {
if (noteId !== '-' && noteId !== getActiveNode().data.noteId) {
console.debug("Switching to " + notePath + " because of hash change");
activateNote(notePath);