Bug Fix for wrong displaying number of pages.