improve pagination a bit