myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mfreed...@apache.org
Subject svn commit: r1131166 - /myfaces/portlet-bridge/core/branches/2.0.0-branch/impl/src/main/java/org/apache/myfaces/portlet/faces/bridge/BridgeImpl.java
Date Fri, 03 Jun 2011 19:47:39 GMT
Author: mfreedman
Date: Fri Jun  3 19:47:39 2011
New Revision: 1131166

URL: http://svn.apache.org/viewvc?rev=1131166&view=rev
Log:
PORTLETBRIDGE-213:  Portlet 2.0 Bridge: FacesMessages not updated in bridge scope if empty.
 

Modified:
    myfaces/portlet-bridge/core/branches/2.0.0-branch/impl/src/main/java/org/apache/myfaces/portlet/faces/bridge/BridgeImpl.java

Modified: myfaces/portlet-bridge/core/branches/2.0.0-branch/impl/src/main/java/org/apache/myfaces/portlet/faces/bridge/BridgeImpl.java
URL: http://svn.apache.org/viewvc/myfaces/portlet-bridge/core/branches/2.0.0-branch/impl/src/main/java/org/apache/myfaces/portlet/faces/bridge/BridgeImpl.java?rev=1131166&r1=1131165&r2=1131166&view=diff
==============================================================================
--- myfaces/portlet-bridge/core/branches/2.0.0-branch/impl/src/main/java/org/apache/myfaces/portlet/faces/bridge/BridgeImpl.java
(original)
+++ myfaces/portlet-bridge/core/branches/2.0.0-branch/impl/src/main/java/org/apache/myfaces/portlet/faces/bridge/BridgeImpl.java
Fri Jun  3 19:47:39 2011
@@ -1797,11 +1797,12 @@ public class BridgeImpl
 
   public void saveFacesMessageState(FacesContext context)
   {
+    FacesMessageState state = new FacesMessageState();
+    
     // get the messages from Faces Context
     Iterator<String> clientIds = context.getClientIdsWithMessages();
     if (clientIds.hasNext())
     {
-      FacesMessageState state = new FacesMessageState();
       while (clientIds.hasNext())
       {
         String clientId = (String) clientIds.next();
@@ -1810,10 +1811,9 @@ public class BridgeImpl
           state.addMessage(clientId, messages.next());
         }
       }
-      // save state in ViewRoot attributes
-      Map<String, Object> requestMap = context.getExternalContext().getRequestMap();
-      requestMap.put(FACES_MESSAGES, state);
     }
+    Map<String, Object> requestMap = context.getExternalContext().getRequestMap();
+    requestMap.put(FACES_MESSAGES, state);
   }
 
   private void restoreFacesMessageState(FacesContext context)



Mime
View raw message