Skip to content

Commit

Permalink
Fix wrong link on displayed atlas entry
Browse files Browse the repository at this point in the history
  • Loading branch information
Hans5958 committed Aug 2, 2023
1 parent dbdad72 commit 571adb1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion web/_js/main/infoblock.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,11 @@ function createInfoBlock(entry, mode = 0) {
const linkElement = document.createElement("a")
linkElement.className = "text-decoration-none d-flex justify-content-between text-body"

const [nearestPeriod, nearestVariation] = getNearestPeriod(entry, currentPeriod, currentVariation)
let nearestPeriod = currentPeriod
let nearestVariation = currentVariation
if (!atlasDisplay[entry.id]) {
[nearestPeriod, nearestVariation] = getNearestPeriod(entry, currentPeriod, currentVariation)
}

if (mode === 2) {
linkElement.href = "#"
Expand Down

0 comments on commit 571adb1

Please sign in to comment.