{% assign version = page.url | remove_first: "/" | split: "/"" | first %} {% assign menu = false %} {% for release in site.data.releases %} {% if version == release.version %} {% assign menu = release.menu %} {% break %} {% endif %} {% endfor %} {% if menu == false %} {% for release in site.data.releases %} {% if true == release.default %} {% assign menu = release.menu %} {% assign version = release.version %} {% break %} {% endif %} {% endfor %} {% endif %}