Fix pagination.