diff options
author | Leif Åstrand <leif@vaadin.com> | 2012-09-21 16:18:17 +0300 |
---|---|---|
committer | Leif Åstrand <leif@vaadin.com> | 2012-09-21 16:18:17 +0300 |
commit | 167ff2bcea28bb5ad4a9ccba4f2b5b9819371390 (patch) | |
tree | f4e9e17b9c9028326702565cff29c37ef8e74828 | |
parent | 115e0343aa65f726f86ccc2b678ca6d5113db760 (diff) | |
download | vaadin-framework-167ff2bcea28bb5ad4a9ccba4f2b5b9819371390.tar.gz vaadin-framework-167ff2bcea28bb5ad4a9ccba4f2b5b9819371390.zip |
Support both ui and UI as the init parameter name (#9707)
-rw-r--r-- | server/src/com/vaadin/server/ServletPortletHelper.java | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/server/src/com/vaadin/server/ServletPortletHelper.java b/server/src/com/vaadin/server/ServletPortletHelper.java index 45c91d1970..e504aa53fb 100644 --- a/server/src/com/vaadin/server/ServletPortletHelper.java +++ b/server/src/com/vaadin/server/ServletPortletHelper.java @@ -119,8 +119,14 @@ class ServletPortletHelper implements Serializable { public static void initDefaultUIProvider(VaadinSession session, VaadinService vaadinService) throws ServiceException { - String uiProperty = vaadinService.getDeploymentConfiguration() - .getInitParameters().getProperty(VaadinSession.UI_PARAMETER); + Properties initParameters = vaadinService.getDeploymentConfiguration() + .getInitParameters(); + String uiProperty = initParameters + .getProperty(VaadinSession.UI_PARAMETER); + if (uiProperty == null) { + uiProperty = initParameters.getProperty(VaadinSession.UI_PARAMETER + .toLowerCase()); + } if (uiProperty != null) { verifyUIClass(uiProperty, vaadinService.getClassLoader()); vaadinService.addUIProvider(session, new DefaultUIProvider()); |