Permalink
Browse files

Only show publish promo to users that can publish

In our no-results template, there's no point in displaying a "publish your first post" promo to users that don't have the ability to publish posts since they can't act on it.
  • Loading branch information...
mjangda committed Aug 31, 2012
1 parent 7fef5cd commit f00245be92d0cba86ace02176b016a55a8538a96
Showing with 1 addition and 1 deletion.
  1. +1 −1 no-results.php
View
@@ -15,7 +15,7 @@
</header><!-- .entry-header -->
<div class="entry-content">
- <?php if ( is_home() ) : ?>
+ <?php if ( is_home() && current_user_can( 'publish_posts' ) ) : ?>
<p><?php printf( __( 'Ready to publish your first post? <a href="%1$s">Get started here</a>.', '_s' ), admin_url( 'post-new.php' ) ); ?></p>

0 comments on commit f00245b

Please sign in to comment.