add fixes on paginate