From 0ca70188994ae04087e25a02a9ac043202fb53ce Mon Sep 17 00:00:00 2001 From: Mark Jaquith Date: Wed, 6 Aug 2008 21:31:40 +0000 Subject: [PATCH] Use the edit_others_posts capability for controlling sticky checkbox display and usage. see #7457 git-svn-id: https://develop.svn.wordpress.org/trunk@8577 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/edit-form-advanced.php | 4 +++- wp-admin/includes/post.php | 10 ++++++---- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/wp-admin/edit-form-advanced.php b/wp-admin/edit-form-advanced.php index 9cce288feb..35d9611141 100644 --- a/wp-admin/edit-form-advanced.php +++ b/wp-admin/edit-form-advanced.php @@ -118,7 +118,9 @@ if ( current_user_can('publish_posts') OR ( $post->post_status == 'publish' AND

-

+ +

+ ID ); - if ( !empty($_POST['sticky']) ) - stick_post($post_ID); - else - unstick_post($post_ID); + if ( current_user_can( 'edit_others_posts' ) ) { + if ( !empty($_POST['sticky']) ) + stick_post($post_ID); + else + unstick_post($post_ID); + } return $post_ID; }