Commit 7879a89a by Tuukka Kivilahti

default locale fixed

1 parent c354f590
...@@ -9,10 +9,6 @@ ...@@ -9,10 +9,6 @@
<f:event type="preRenderView" listener="#{pageOutputView.initIndexView}" /> <f:event type="preRenderView" listener="#{pageOutputView.initIndexView}" />
</f:metadata> </f:metadata>
<ui:define name="content"> <ui:define name="content">
<h:outputLabel rendered="#{sessionHandler.isInDevelopmentMode()}">
Development-tilassa.
Täällä voit huoletta rikkoa.
</h:outputLabel>
<ui:fragment rendered="#{layoutView.manageContent}"> <ui:fragment rendered="#{layoutView.manageContent}">
<h:link value="#{i18n['layout.editContent']}" outcome="/pages/manage"> <h:link value="#{i18n['layout.editContent']}" outcome="/pages/manage">
<f:param name="pagename" value="#{layoutView.pagepath}" /> <f:param name="pagename" value="#{layoutView.pagepath}" />
......
...@@ -47,7 +47,7 @@ public class SessionStore implements Serializable { ...@@ -47,7 +47,7 @@ public class SessionStore implements Serializable {
public Locale getLocale() { public Locale getLocale() {
Locale ret = locale; Locale ret = locale;
if (ret == null) if (ret == null || ret.toString().equals(""))
{ {
String retStr = eventbean.getCurrentEvent().getOrganiser().getBundleCountry(); String retStr = eventbean.getCurrentEvent().getOrganiser().getBundleCountry();
...@@ -60,11 +60,13 @@ public class SessionStore implements Serializable { ...@@ -60,11 +60,13 @@ public class SessionStore implements Serializable {
} }
} }
if (ret == null) { if (ret == null || ret.toString().equals("")) {
ret = DEFAULT_LOCALE; ret = DEFAULT_LOCALE;
} }
locale = ret; locale = ret;
} }
logger.info("Using locale {}",ret);
return ret; return ret;
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!