[wp-trac] [WordPress Trac] #29607: image_add_caption() returns immediately if caption empty, preventing filter from firing

WordPress Trac noreply at wordpress.org
Tue Nov 4 16:38:36 UTC 2014


#29607: image_add_caption() returns immediately if caption empty, preventing filter
from firing
--------------------------------------------+------------------------------
 Reporter:  paulschreiber                   |       Owner:  SergeyBiryukov
     Type:  enhancement                     |      Status:  closed
 Priority:  normal                          |   Milestone:  4.1
Component:  Media                           |     Version:  trunk
 Severity:  normal                          |  Resolution:  fixed
 Keywords:  needs-testing has-patch commit  |     Focuses:  docs,
                                            |  administration
--------------------------------------------+------------------------------
Changes (by DrewAPicture):

 * status:  reopened => closed
 * resolution:   => fixed


Comment:

 @MikeHansenMe is correct in comment:13. We need to preserve the existing
 behavior of the `disable_caption` filter so the new filter added in
 [29753] should give you enough rope to manage that. Even passing something
 like a non-breaking space would bypass the empty/`disable_caption` check.

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


More information about the wp-trac mailing list