fix the page refresh