[wp-trac] [WordPress Trac] #56609: Handbook - links pointing to is_wp_error function
WordPress Trac
noreply at wordpress.org
Wed Sep 21 03:08:29 UTC 2022
#56609: Handbook - links pointing to is_wp_error function
-------------------------------------+------------------------------
Reporter: dingo_d | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version:
Severity: normal | Resolution:
Keywords: needs-patch 2nd-opinion | Focuses: docs
-------------------------------------+------------------------------
Changes (by dd32):
* keywords: 2nd-opinion has-patch => needs-patch 2nd-opinion
Comment:
This is caused by [54234] in some way I believe (cc @peterwilsoncc)
{{{
wp> get_page_by_title( 'wp_insert_post', OBJECT, 'wp-parser-function'
)->post_title;
string(11) "is_wp_error"
Last Query:
SELECT wp_posts.ID
FROM wp_posts
WHERE 1=1 AND wp_posts.post_type = 'wp-parser-function' AND
((wporg_33_posts.post_status = 'publish' OR wp_posts.post_status =
'future' OR wp_posts.post_status = 'draft' OR wp_posts.post_status =
'pending' OR wp_posts.post_status = 'trash' OR wp_posts.post_status =
'auto-draft' OR wp_posts.post_status = 'inherit' OR wp_posts.post_status =
'private'))
ORDER BY wp_posts.ID ASC
LIMIT 0, 1
Called via WP_CLI\Shell\REPL->start, eval, get_page_by_title,
WP_Query->__construct, WP_Query->query, WP_Query->get_posts, wpdb->get_col
}}}
(Note, I've slimmed the query, removing some plugin-related statuses)
Looks like `post_title` isn't a valid WP_Query field, but `title` is, so
I'm not sure how the tests in #36905 succeeded. See
https://github.com/WordPress/wordpress-develop/pull/3300
--
Ticket URL: <https://core.trac.wordpress.org/ticket/56609#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list