roller-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gango...@apache.org
Subject svn commit: r729448 - /roller/branches/roller_4.0/apps/weblogger/src/java/org/apache/roller/weblogger/ui/rendering/model/SearchResultsModel.java
Date Thu, 25 Dec 2008 22:30:41 GMT
Author: gangolli
Date: Thu Dec 25 14:30:40 2008
New Revision: 729448

URL: http://svn.apache.org/viewvc?rev=729448&view=rev
Log:
Integrated fix for ROL-1766 to roller_4.0 branch

Modified:
    roller/branches/roller_4.0/apps/weblogger/src/java/org/apache/roller/weblogger/ui/rendering/model/SearchResultsModel.java
  (contents, props changed)

Modified: roller/branches/roller_4.0/apps/weblogger/src/java/org/apache/roller/weblogger/ui/rendering/model/SearchResultsModel.java
URL: http://svn.apache.org/viewvc/roller/branches/roller_4.0/apps/weblogger/src/java/org/apache/roller/weblogger/ui/rendering/model/SearchResultsModel.java?rev=729448&r1=729447&r2=729448&view=diff
==============================================================================
--- roller/branches/roller_4.0/apps/weblogger/src/java/org/apache/roller/weblogger/ui/rendering/model/SearchResultsModel.java
(original)
+++ roller/branches/roller_4.0/apps/weblogger/src/java/org/apache/roller/weblogger/ui/rendering/model/SearchResultsModel.java
Thu Dec 25 14:30:40 2008
@@ -27,6 +27,7 @@
 import java.util.TreeSet;
 import org.apache.commons.collections.comparators.ReverseComparator;
 import org.apache.commons.lang.StringUtils;
+import org.apache.commons.lang.StringEscapeUtils;
 import org.apache.lucene.document.Document;
 import org.apache.lucene.search.Hits;
 import org.apache.roller.weblogger.WebloggerException;
@@ -47,6 +48,7 @@
 import org.apache.roller.util.DateUtil;
 import org.apache.roller.weblogger.business.URLStrategy;
 import org.apache.roller.weblogger.util.I18nMessages;
+import org.apache.roller.weblogger.util.Utilities;
 
 
 /**
@@ -232,6 +234,11 @@
     
     
     public String getTerm() {
+        String query = searchRequest.getQuery();
+        return (query == null) ? "" : StringEscapeUtils.escapeXml(Utilities.escapeHTML(query));
+    }
+
+    public String getRawTerm() {
         return (searchRequest.getQuery() == null) ? "" : searchRequest.getQuery();
     }
 

Propchange: roller/branches/roller_4.0/apps/weblogger/src/java/org/apache/roller/weblogger/ui/rendering/model/SearchResultsModel.java
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Thu Dec 25 14:30:40 2008
@@ -0,0 +1 @@
+/roller/trunk/apps/weblogger/src/java/org/apache/roller/weblogger/ui/rendering/model/SearchResultsModel.java:596879-729447



Mime
View raw message