[wp-trac] [WordPress Trac] #57587: Method get_term_link() isn't type save - (Attempt to read property "query_var" on bool)
WordPress Trac
noreply at wordpress.org
Tue Jan 31 06:39:02 UTC 2023
#57587: Method get_term_link() isn't type save - (Attempt to read property
"query_var" on bool)
-------------------------------+------------------------------
Reporter: 1benk1 | Owner: (none)
Type: defect (bug) | Status: closed
Priority: normal | Milestone: Awaiting Review
Component: Taxonomy | Version: 6.1.1
Severity: normal | Resolution: wontfix
Keywords: reporter-feedback | Focuses:
-------------------------------+------------------------------
Changes (by 1benk1):
* status: new => closed
* resolution: => wontfix
Comment:
After some debugging I found out that $term is not a WP_Term object, but
the MultipleAuthors\Classes\Objects\Author class of a plugin
(https://github.com/publishpress/PublishPress-
Authors/blob/development/src/core/Classes/Objects/Author.php).
We used get_term_link() with the return value of get_queried_object()
(https://developer.wordpress.org/reference/functions/get_queried_object/)
and the documenation of this Method is suggesting, that the return values
can only be WP_Term|WP_Post_Type|WP_Post|WP_User|null.
This report can be closed...
--
Ticket URL: <https://core.trac.wordpress.org/ticket/57587#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list