paginator fix for the last page

paginator fix for the last page