move page specific logic back