A custom front page can't be set if the site option show_on_front is set to posts. The private function _reset_front_page_settings_for_post is added as an action to the before_delete_post and wp_trash_post hooks; if the page assigned to the page_on_front option is deleted, this function changes the show_on_front option to posts, meaning that a new front page can't be assigned until show_on_front is set to page again. Aldine doesn't use posts, and there's no interface to change what's shown on the front page from a page to posts or vice versa exposed in Aldine (the reading options page is hidden). I resolved the issue by unhooking the _reset_front_page_settings_for_post function. Now, if the selected front page is deleted, the home page will show a 404 until a new one is selected in the customizer.
Resolves #402.
A custom front page can't be set if the site option
show_on_front
is set toposts
. The private function_reset_front_page_settings_for_post
is added as an action to thebefore_delete_post
andwp_trash_post
hooks; if the page assigned to thepage_on_front
option is deleted, this function changes theshow_on_front
option toposts
, meaning that a new front page can't be assigned untilshow_on_front
is set topage
again. Aldine doesn't use posts, and there's no interface to change what's shown on the front page from a page to posts or vice versa exposed in Aldine (the reading options page is hidden). I resolved the issue by unhooking the_reset_front_page_settings_for_post
function. Now, if the selected front page is deleted, the home page will show a 404 until a new one is selected in the customizer.