Skip to content

Commit

Permalink
updated to check for nag string, fallback to updated class if it is n…
Browse files Browse the repository at this point in the history
…ot set
  • Loading branch information
thomasgriffin committed Apr 16, 2012
1 parent 3951e67 commit bfb09dd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions tgm-plugin-activation/class-tgm-plugin-activation.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Plugin installation and activation for WordPress themes.
*
* @package TGM-Plugin-Activation
* @version 2.3.4
* @version 2.3.5
* @author Thomas Griffin <thomas@thomasgriffinmedia.com>
* @author Gary Jones <gamajo@gamajo.com>
* @copyright Copyright (c) 2012, Thomas Griffin
Expand Down Expand Up @@ -708,8 +708,10 @@ public function notices() {
$rendered .= '<p>' . implode( ' | ', $action_links ) . '</p>';

/** Register the nag messages and prepare them to be processed */
if ( isset( $this->strings['nag_type'] ) )
if ( isset( $this->strings['nag_type'] ) )
add_settings_error( 'tgmpa', 'tgmpa', $rendered, sanitize_html_class( strtolower( $this->strings['nag_type'] ), 'updated' ) );
else
add_settings_error( 'tgmpa', 'tgmpa', $rendered, 'updated' );
}
}

Expand Down
2 changes: 1 addition & 1 deletion tgm-plugin-activation/example.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
*
* @package TGM-Plugin-Activation
* @subpackage Example
* @version 2.3.4
* @version 2.3.5
* @author Thomas Griffin <thomas@thomasgriffinmedia.com>
* @author Gary Jones <gamajo@gamajo.com>
* @copyright Copyright (c) 2012, Thomas Griffin
Expand Down

0 comments on commit bfb09dd

Please sign in to comment.