removing Silly mistakes in pagination