[richfaces-svn-commits] JBoss Rich Faces SVN: r8906 - trunk/ui/suggestionbox/src/main/java/org/richfaces/renderkit/html.

richfaces-svn-commits at lists.jboss.org richfaces-svn-commits at lists.jboss.org
Wed Jun 4 15:37:09 EDT 2008


Author: nbelaevski
Date: 2008-06-04 15:37:09 -0400 (Wed, 04 Jun 2008)
New Revision: 8906

Modified:
   trunk/ui/suggestionbox/src/main/java/org/richfaces/renderkit/html/SuggestionBoxRenderer.java
Log:
Minor optimization for SuggestionBoxRenderer

Modified: trunk/ui/suggestionbox/src/main/java/org/richfaces/renderkit/html/SuggestionBoxRenderer.java
===================================================================
--- trunk/ui/suggestionbox/src/main/java/org/richfaces/renderkit/html/SuggestionBoxRenderer.java	2008-06-04 19:34:57 UTC (rev 8905)
+++ trunk/ui/suggestionbox/src/main/java/org/richfaces/renderkit/html/SuggestionBoxRenderer.java	2008-06-04 19:37:09 UTC (rev 8906)
@@ -863,13 +863,15 @@
     		renderChild(context, nothingLabelFacet);
     		writer.write(endHtml);
     	} 
-    	else if (null != suggestionBox.getNothingLabel() && 
-    			!"".equals(suggestionBox.getNothingLabel())) {
-    		writer.write(startHtml);
-    		writer.write(suggestionBox.getNothingLabel());
-    		writer.write(endHtml);
+    	else {
+    		String nothingLabel = suggestionBox.getNothingLabel();
+			if (null != nothingLabel && 
+    				!"".equals(nothingLabel)) {
+    			writer.write(startHtml);
+    			writer.write(nothingLabel);
+    			writer.write(endHtml);
+    		}
     	}
-    	
     }
     
     /**




More information about the richfaces-svn-commits mailing list