[wp-trac] [WordPress Trac] #21787: While editing post, View Post link disappears if post status gets set to anything other than 'publish'
WordPress Trac
wp-trac at lists.automattic.com
Wed Sep 5 17:39:22 UTC 2012
#21787: While editing post, View Post link disappears if post status gets set to
anything other than 'publish'
--------------------------+------------------------------
Reporter: ericlewis | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Editor | Version:
Severity: normal | Resolution:
Keywords: has-patch |
--------------------------+------------------------------
Comment (by azaozz):
Hmm, that `current_user_can()` is redundant. Is there a case where a user
can edit a post but cannot view it? The fix would be:
{{{
if ( 'publish' == $post->post_status || 'private' == $post->post_status )
...
}}}
--
Ticket URL: <http://core.trac.wordpress.org/ticket/21787#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list