roller-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gma...@apache.org
Subject svn commit: r1599070 - /roller/trunk/app/src/main/java/org/apache/roller/weblogger/business/jpa/JPAWeblogEntryManagerImpl.java
Date Sun, 01 Jun 2014 22:30:19 GMT
Author: gmazza
Date: Sun Jun  1 22:30:19 2014
New Revision: 1599070

URL: http://svn.apache.org/r1599070
Log:
ROL-1716 fix illegal state exception in getPopularTags when unlimited tags (-1) is requested.

Modified:
    roller/trunk/app/src/main/java/org/apache/roller/weblogger/business/jpa/JPAWeblogEntryManagerImpl.java

Modified: roller/trunk/app/src/main/java/org/apache/roller/weblogger/business/jpa/JPAWeblogEntryManagerImpl.java
URL: http://svn.apache.org/viewvc/roller/trunk/app/src/main/java/org/apache/roller/weblogger/business/jpa/JPAWeblogEntryManagerImpl.java?rev=1599070&r1=1599069&r2=1599070&view=diff
==============================================================================
--- roller/trunk/app/src/main/java/org/apache/roller/weblogger/business/jpa/JPAWeblogEntryManagerImpl.java
(original)
+++ roller/trunk/app/src/main/java/org/apache/roller/weblogger/business/jpa/JPAWeblogEntryManagerImpl.java
Sun Jun  1 22:30:19 2014
@@ -966,7 +966,7 @@ public class JPAWeblogEntryManagerImpl i
         double min = Integer.MAX_VALUE;
         double max = Integer.MIN_VALUE;
         
-        List<TagStat> results = new ArrayList<TagStat>(limit);
+        List<TagStat> results = new ArrayList<TagStat>(limit >= 0 ? limit
: 25);
         
         for (Iterator iter = queryResults.iterator(); iter.hasNext();) {
             Object[] row = (Object[]) iter.next();



Mime
View raw message