[wp-trac] [WordPress Trac] #60646: Docs: Incorrect return type specified for get_post_custom with negative post ID value
WordPress Trac
noreply at wordpress.org
Tue Feb 27 15:26:26 UTC 2024
#60646: Docs: Incorrect return type specified for get_post_custom with negative
post ID value
----------------------------------------+------------------------------
Reporter: roytanck | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Posts, Post Types | Version: 5.8
Severity: trivial | Resolution:
Keywords: needs-patch good-first-bug | Focuses: docs
----------------------------------------+------------------------------
Changes (by swissspidy):
* keywords: => needs-patch good-first-bug
* version: => 5.8
Comment:
The incorrect docs were added in [52795] / #55249
It was added because the underlying `get_post_meta` and `get_metadata_raw`
functions have the same note about negative values. Introduced in [50641]
/ #51797. Thus setting the version here to 5.8.
So the problem is a bit more widespread and the docblock needs to be
updated for more functions than just `get_post_custom`. There are about 8
occurrences of "(non-numeric, zero, or negative value)" in core at the
moment .
--
Ticket URL: <https://core.trac.wordpress.org/ticket/60646#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list