Fixed bug of using page-name to set url's instead of slug