Skip to content

Commit

Permalink
Change limit of intiterator to function as from ... to, fixes #85
Browse files Browse the repository at this point in the history
  • Loading branch information
benmerckx committed Dec 28, 2019
1 parent 856e0db commit 68d571b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/tink/sql/Limit.hx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ private typedef LimitData = {
abstract Limit(LimitData) from LimitData to LimitData {

@:from static function ofIter(i:IntIterator):Limit
return @:privateAccess { limit: i.min, offset: i.max };
return @:privateAccess { limit: i.max - i.min, offset: i.min };

@:from static function ofInt(i:Int):Limit
return { limit: i, offset: 0 };
Expand Down

0 comments on commit 68d571b

Please sign in to comment.