fix some paging issues