aboutsummaryrefslogtreecommitdiff
path: root/frontend
diff options
context:
space:
mode:
Diffstat (limited to 'frontend')
-rw-r--r--frontend/utility.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/frontend/utility.go b/frontend/utility.go
index 28e7db1..6dbef6a 100644
--- a/frontend/utility.go
+++ b/frontend/utility.go
@@ -13,7 +13,7 @@ func PaginationFromPage(pageRange, currentPage, maxPage int) PaginationRange {
13 var after []int 13 var after []int
14 14
15 startPage := currentPage - pageRange 15 startPage := currentPage - pageRange
16 endPage := currentPage + pageRange + 1 16 endPage := currentPage + pageRange
17 17
18 if startPage < 1 { 18 if startPage < 1 {
19 endPage += -startPage + 1 19 endPage += -startPage + 1
@@ -36,7 +36,7 @@ func PaginationFromPage(pageRange, currentPage, maxPage int) PaginationRange {
36 before = append(before, i) 36 before = append(before, i)
37 } 37 }
38 38
39 for i := currentPage + 1; i < endPage; i++ { 39 for i := currentPage + 1; i < endPage+1; i++ {
40 after = append(after, i) 40 after = append(after, i)
41 } 41 }
42 42