fix  the previous page and next page path bug