[wp-trac] [WordPress Trac] #30287: Private posts skipped in single post navigation

WordPress Trac noreply at wordpress.org
Sat Nov 8 21:15:46 UTC 2014


#30287: Private posts skipped in single post navigation
--------------------------+------------------------------
 Reporter:  blogan        |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  General       |     Version:  trunk
 Severity:  normal        |  Resolution:
 Keywords:                |     Focuses:
--------------------------+------------------------------

Comment (by valendesigns):

 The issue is with the query in the `get_adjacent_post()` functions that
 only allows for published posts.

 {{{
 WHERE p.post_date $op %s AND p.post_type = %s AND p.post_status =
 'publish'
 }}}

 Changing it to the following could solve this, but I don't know if it's as
 straight forward as that because there's no logged in check and I'm fairly
 certain we don't want to run this altered query for every user.
 {{{
 WHERE p.post_date $op %s AND p.post_type = %s AND p.post_status = IN
 ('publish', 'private')
 }}}

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


More information about the wp-trac mailing list