Skip to content

Commit

Permalink
Fix #47
Browse files Browse the repository at this point in the history
  • Loading branch information
MinusKube committed Feb 14, 2019
1 parent f385d2f commit 25afe94
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main/java/fr/minuskube/inv/content/Pagination.java
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ public boolean isFirst() {

@Override
public boolean isLast() {
return this.currentPage == this.items.length / this.itemsPerPage;
int pageCount = (int) Math.ceil((double) this.items.length / this.itemsPerPage);
return this.currentPage == pageCount - 1;
}

@Override
Expand Down

0 comments on commit 25afe94

Please sign in to comment.