From 167ff2bcea28bb5ad4a9ccba4f2b5b9819371390 Mon Sep 17 00:00:00 2001 From: Leif Åstrand Date: Fri, 21 Sep 2012 16:18:17 +0300 Subject: Support both ui and UI as the init parameter name (#9707) --- server/src/com/vaadin/server/ServletPortletHelper.java | 10 ++++++++-- 1 file 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()); -- cgit v1.2.3