However, they don't like it when the report returns less than a pageful of rows and they see this:
(Fussy, I know).
This is one way to do it. First, ensure that the pagination area itself is identifiable. I put a div around it with a class of "pagination":
if ($(this).find('td.pagination a').length == 0
&& $(this).find('div.msg').length == 0
It looks for pagination areas that contain no links and no “reset pagination” error message, and hides them.