[wp-trac] [WordPress Trac] #25334: With custom page templates set per page, surprising behavior after switching themes
WordPress Trac
noreply at wordpress.org
Thu Jan 1 20:34:24 UTC 2015
#25334: With custom page templates set per page, surprising behavior after
switching themes
--------------------------+-----------------------------
Reporter: ericlewis | Owner: wonderboymusic
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 4.2
Component: Themes | Version: 3.8
Severity: normal | Resolution: fixed
Keywords: has-patch | Focuses: administration
--------------------------+-----------------------------
Changes (by wonderboymusic):
* owner: => wonderboymusic
* status: new => closed
* resolution: => fixed
Comment:
In [changeset:"31020"]:
{{{
#!CommitTicketReference repository="" revision="31020"
If you set `'_wp_page_template'` for a post, and then switch to a theme
that doesn't support the template, subsequent calls to `wp_insert_post()`
will bail early without running a plethora of hooks. This shouldn't
happen. We should set the template to `'default'` and continue through the
rest of the function. The function will still bail if `$wp_error` is
`true` via `wp_insert_post( $arr, true )`.
Props nofearinc.
Fixes #25334.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/25334#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list