From 0620fa5c061b83141e00daeabc5e7ee982e0de55 Mon Sep 17 00:00:00 2001 From: Steve Manuel Date: Tue, 1 Nov 2016 23:56:24 -0700 Subject: testing start / end positions on cursor --- system/db/content.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'system') diff --git a/system/db/content.go b/system/db/content.go index 9aa86d8..8058cad 100644 --- a/system/db/content.go +++ b/system/db/content.go @@ -233,7 +233,7 @@ func Query(namespace string, opts QueryOptions) [][]byte { switch opts.Order { case "asc": for k, v := c.Last(); k != nil; c.Prev() { - if start < cur && cur < end { + if cur < end { cur++ continue } @@ -248,7 +248,7 @@ func Query(namespace string, opts QueryOptions) [][]byte { case "desc": for k, v := c.First(); k != nil; c.Next() { - if start < cur && cur < end { + if cur < start { cur++ continue } -- cgit v1.2.3