locations keeps changing after every page refresh