Skip to content

Commit

Permalink
Remove currentURL
Browse files Browse the repository at this point in the history
  • Loading branch information
coltborg committed Jul 11, 2023
1 parent 0fdca8c commit cf16a31
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/main/resources/templates/fragments/languageSelector.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
class="language-selector"
th:with="
lang=${#locale.toString()},
currentURL=${screen},
appPropsLanguages=${#strings.replace(@environment.getProperty('form-flow.languages'), ' ', '')},
supportedLanguages=${appPropsLanguages != null ? appPropsLanguages.split(',') : 'default'},
useLinksForDesktopView=${#arrays.length(supportedLanguages) <= 3}
Expand All @@ -30,15 +29,15 @@
<li th:each="language : ${supportedLanguages}" role="none">
<a th:text="${#messages.msg('language-preferences.link-text.' + language)}"
th:lang="${language}"
th:href="|${currentURL}?lang=${language}|"
th:href="|?lang=${language}|"
class="text--small language-option-track-click" role="menuitem"></a>
</li>
</ul>
<div class="translate-links"
th:classappend="${useLinksForDesktopView ? 'use-links-for-desktop' : ''}">
<a th:each="language : ${supportedLanguages}"
th:text="${#messages.msg('language-preferences.link-text.' + language)}"
th:href="|${currentURL}?lang=${language}|"></a>
th:href="|?lang=${language}|"></a>
</div>
<noscript>
<!-- When JavaScript is disabled, hide translate button and show translate links -->
Expand Down

0 comments on commit cf16a31

Please sign in to comment.