You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@empire-db.apache.org by do...@apache.org on 2024/04/22 17:22:02 UTC

(empire-db) branch master updated: EMPIREDB-424 FacesConfiguration fix

This is an automated email from the ASF dual-hosted git repository.

doebele pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/empire-db.git


The following commit(s) were added to refs/heads/master by this push:
     new 63c70c9a EMPIREDB-424 FacesConfiguration fix
63c70c9a is described below

commit 63c70c9affa93d1aff93b7f42d881d8d9bc61f3e
Author: Rainer Döbele <do...@apache.org>
AuthorDate: Mon Apr 22 19:21:59 2024 +0200

    EMPIREDB-424
    FacesConfiguration fix
---
 .../src/main/java/org/apache/empire/jsf2/app/FacesConfiguration.java | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/empire-db-jsf2/src/main/java/org/apache/empire/jsf2/app/FacesConfiguration.java b/empire-db-jsf2/src/main/java/org/apache/empire/jsf2/app/FacesConfiguration.java
index d0401e72..e3704b16 100644
--- a/empire-db-jsf2/src/main/java/org/apache/empire/jsf2/app/FacesConfiguration.java
+++ b/empire-db-jsf2/src/main/java/org/apache/empire/jsf2/app/FacesConfiguration.java
@@ -317,7 +317,6 @@ public class FacesConfiguration
         if (ProjectStage.PROJECT_STAGE_PARAM_NAME.equals(paramName))
             throw new UnspecifiedErrorException(ProjectStage.PROJECT_STAGE_PARAM_NAME+" cannot be changed!");
         // get map
-        Map<String,String> paramMap = (Map<String,String>)this.externalContext.getInitParameterMap();
         String paramVal = StringUtils.toString(paramValue);
         String orgValue = this.externalContext.getInitParameter(paramName);
         if (ObjectUtils.compareEqual(paramVal, orgValue))
@@ -331,6 +330,10 @@ public class FacesConfiguration
             log.info("Setting FacesParam \"{}\" to \"{}\". Original value was \"{}\"", paramName, paramVal, orgValue);
         else
             log.info("Setting FacesParam \"{}\" to \"{}\".", paramName, paramVal);
+        // add to map
+        @SuppressWarnings("unchecked")
+        Map<String,String> paramMap = this.externalContext.getInitParameterMap();
+        paramMap.put(paramName, paramVal);
     }
 
     protected void setFacesInitParam(String paramName, Object paramValue)