made pages refresh on back button press