[wp-trac] [WordPress Trac] #55176: if $stickies in function stick_post is not array, it should be empty array

WordPress Trac noreply at wordpress.org
Thu Apr 21 06:02:36 UTC 2022


#55176: if  $stickies in function stick_post is not array, it should be empty array
-------------------------------------------------+-------------------------
 Reporter:  denishua                             |       Owner:
                                                 |  peterwilsoncc
     Type:  defect (bug)                         |      Status:  closed
 Priority:  normal                               |   Milestone:  6.0
Component:  Posts, Post Types                    |     Version:  5.7
 Severity:  normal                               |  Resolution:  fixed
 Keywords:  has-patch has-unit-tests needs-      |     Focuses:
  testing                                        |
-------------------------------------------------+-------------------------
Changes (by peterwilsoncc):

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


Comment:

 In [changeset:"53238" 53238]:
 {{{
 #!CommitTicketReference repository="" revision="53238"
 Posts, Post Types: Fix option validation in `stick_post()`.

 Normalize an invalid `sticky_posts` option to an empty array within
 `stick_post()`. This fixes a bug in which an unexpected option value would
 prevent new posts from being made sticky.

 Follow up to [50380].

 Props azouamauriac, denishua, kajalgohel, sergeybiryukov, costdev.
 Fixes #55176.
 }}}

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


More information about the wp-trac mailing list