Possible fix of issue #365
This commit is contained in:
parent
2fb4b5c967
commit
132d3dc66e
|
@ -150,19 +150,14 @@ public class FlattrUtils {
|
||||||
final int FLATTR_COUNT = 30;
|
final int FLATTR_COUNT = 30;
|
||||||
final int FLATTR_MAXPAGE = 5;
|
final int FLATTR_MAXPAGE = 5;
|
||||||
|
|
||||||
int page = 0;
|
for (int page = 0; page < FLATTR_MAXPAGE; page++) {
|
||||||
do {
|
|
||||||
myFlattrs.ensureCapacity(FLATTR_COUNT*(page+1));
|
|
||||||
|
|
||||||
for (Flattr fl: fs.getMyFlattrs(FLATTR_COUNT, page)) {
|
for (Flattr fl: fs.getMyFlattrs(FLATTR_COUNT, page)) {
|
||||||
if (fl.getCreated().after(firstOfMonthDate))
|
if (fl.getCreated().after(firstOfMonthDate))
|
||||||
myFlattrs.add(fl);
|
myFlattrs.add(fl);
|
||||||
else
|
else
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
page++;
|
|
||||||
}
|
}
|
||||||
while (myFlattrs.get(myFlattrs.size()-1).getCreated().after( firstOfMonthDate ) && page < FLATTR_MAXPAGE);
|
|
||||||
|
|
||||||
if (AppConfig.DEBUG) {
|
if (AppConfig.DEBUG) {
|
||||||
Log.d(TAG, "Got my flattrs list of length " + Integer.toString(myFlattrs.size()) + " comparison date" + firstOfMonthDate);
|
Log.d(TAG, "Got my flattrs list of length " + Integer.toString(myFlattrs.size()) + " comparison date" + firstOfMonthDate);
|
||||||
|
|
Loading…
Reference in New Issue