Skip to content

Commit

Permalink
Fix paging
Browse files Browse the repository at this point in the history
  • Loading branch information
maeb committed Apr 27, 2021
1 parent 5e871e1 commit 094e7c3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions internal/scylla/logserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,7 @@ func listPageLogsByExecutionId(query *gocqlx.Queryx, req *logV1.PageLogListReque
iter := query.BindMap(qb.M{"execution_id": executionId}).Iter()
for pageLog := new(PageLog); iter.StructScan(pageLog); pageLog = new(PageLog) {
if count < offset {
count++
continue
}
err := fn(pageLog.toProto())
Expand Down Expand Up @@ -388,6 +389,7 @@ func listCrawlLogsByExecutionId(query *gocqlx.Queryx, req *logV1.CrawlLogListReq
iter := query.BindMap(qb.M{"execution_id": executionId}).Iter()
for crawlLog := new(CrawlLog); iter.StructScan(crawlLog); crawlLog = new(CrawlLog) {
if count < offset {
count++
continue
}
err := fn(crawlLog.toProto())
Expand Down

0 comments on commit 094e7c3

Please sign in to comment.