[wp-trac] [WordPress Trac] #37291: Check for WP_Error before echo in the_tags()

WordPress Trac noreply at wordpress.org
Tue Oct 11 01:43:16 UTC 2016


#37291: Check for WP_Error before echo in the_tags()
-------------------------------------+--------------------
 Reporter:  michalzuber              |       Owner:
     Type:  defect (bug)             |      Status:  new
 Priority:  normal                   |   Milestone:  4.6.2
Component:  Taxonomy                 |     Version:
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-testing  |     Focuses:
-------------------------------------+--------------------

Comment (by dd32):

 @boonebgorges That looks like it does exactly what I was thinking, I was
 for some reason having difficulty in writing that same patch while dug in
 deep. I also assume there's a PHPDoc update to go with that though.

 One case I was worried about was where it'd just continuously return a
 `WP_Error` when the cache was invalid, however by switching purely to
 `get_term()` that would cause it to fall back to the database anyway,
 correct?

--
Ticket URL: <https://core.trac.wordpress.org/ticket/37291#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list