Simplified pagination further

Also cleaned up a bunch of other things