Show Quick Press only if user can publish posts. fixes #8108

git-svn-id: https://develop.svn.wordpress.org/trunk@9628 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2008-11-12 04:55:47 +00:00
parent 9dce538b95
commit 66b4d45e4e
1 changed files with 2 additions and 1 deletions

View File

@ -48,7 +48,8 @@ function wp_dashboard_setup() {
wp_add_dashboard_widget( 'dashboard_plugins', __( 'Plugins' ), 'wp_dashboard_plugins' );
// QuickPress Widget
wp_add_dashboard_widget( 'dashboard_quick_press', __( 'QuickPress' ), 'wp_dashboard_quick_press' );
if ( current_user_can('publish_posts') )
wp_add_dashboard_widget( 'dashboard_quick_press', __( 'QuickPress' ), 'wp_dashboard_quick_press' );
// Recent Drafts
wp_add_dashboard_widget( 'dashboard_recent_drafts', sprintf( __( 'Recent Drafts <a href="%s">View all</a>' ), 'edit.php?post_status=draft' ), 'wp_dashboard_recent_drafts' );