Issue when going back and forward using browser buttons after clicking logo to go to home page