updated routes so that documents remain on refresh