fixed it so that pages dont have duplicates