Skip to content

Commit

Permalink
Fix #177: Locale is not set in testing
Browse files Browse the repository at this point in the history
  • Loading branch information
FroMage committed Oct 27, 2023
1 parent 12085c9 commit 1114e07
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions runtime/src/main/java/io/quarkiverse/renarde/util/I18N.java
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public String get() {
* @return the language part of the current locale
*/
public String getLanguage() {
return locale.getLanguage();
return getLocale().getLanguage();
}

/**
Expand All @@ -89,7 +89,7 @@ public String getLanguage() {
* @return the current locale, as obtained via a cookie override, or HTTP headers, or the default.
*/
public Locale getLocale() {
return locale;
return locale != null ? locale : localesConfig.defaultLocale;
}

void readLanguageCookie(ResteasyReactiveContainerRequestContext requestContext) {
Expand Down

0 comments on commit 1114e07

Please sign in to comment.