fixing pagination/pagesort conflicts