Fixed bug when first creating a page.