Skip to content

Commit

Permalink
Changed admin notices so they only show for admins
Browse files Browse the repository at this point in the history
  • Loading branch information
gyrus committed May 7, 2015
1 parent 4173b51 commit ed659e9
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
3 changes: 3 additions & 0 deletions readme.txt
Expand Up @@ -91,6 +91,9 @@ Please raise any issues via [GitHub](https://github.com/gyrus/WordPress-Develope
**NOTE:** Some people have found compatibility issues between the [WPMU DEV Events+](http://premium.wpmudev.org/project/events-plus/) plugin and this plugin (see [here](https://github.com/gyrus/WordPress-Developers-Custom-Fields/issues/23) and [here](https://github.com/gyrus/WordPress-Developers-Custom-Fields/issues/24)). If you find an apparent issue with this plugin and you're also using WPMU DEV Events+, please check for incompatibilities before posting an issue.

== Changelog ==
= 1.2.2 =
* Changed admin notices so they only show for admins

= 1.2.1 =
* Better version suffixes for styles

Expand Down
2 changes: 1 addition & 1 deletion slt-cf-admin.php
Expand Up @@ -14,7 +14,7 @@
function slt_cf_admin_notices() {
global $slt_cf_admin_notices;

if ( ! empty( $slt_cf_admin_notices ) ) {
if ( ! empty( $slt_cf_admin_notices ) && current_user_can( 'update_core' ) ) {
foreach ( $slt_cf_admin_notices as $notice ) { ?>
<div class="notice updated slt-cf-notice">
<p><strong><?php echo $notice['label']; ?>:</strong> <?php echo $notice['text']; ?></p>
Expand Down
4 changes: 2 additions & 2 deletions slt-custom-fields.php
Expand Up @@ -9,7 +9,7 @@
Plugin URI: http://wordpress.org/extend/plugins/developers-custom-fields/
Description: Provides theme developers with tools for managing custom fields.
Author: Steve Taylor
Version: 1.2.1
Version: 1.2.2
Author URI: http://sltaylor.co.uk
License: GPLv2
Text Domain: slt-custom-fields
Expand Down Expand Up @@ -50,7 +50,7 @@
define( 'SLT_CF_TITLE', "Developer's Custom Fields" );
define( 'SLT_CF_NO_OPTIONS', __( 'No options to choose from', SLT_CF_TEXT_DOMAIN ) );
define( 'SLT_CF_REQUEST_PROTOCOL', isset( $_SERVER[ 'HTTPS' ] ) ? 'https://' : 'http://' );
define( 'SLT_CF_VERSION', '1.2.1' );
define( 'SLT_CF_VERSION', '1.2.2' );
define( 'SLT_CF_PRIMARY_FILE_PATH', plugin_basename( __FILE__ ) );
$slt_custom_fields = array();
$slt_custom_fields['prefix'] = '_slt_';
Expand Down

0 comments on commit ed659e9

Please sign in to comment.