Skip to content

Commit

Permalink
Update to TGMPA
Browse files Browse the repository at this point in the history
  • Loading branch information
Vlad Olaru committed Apr 10, 2020
1 parent bdaedc6 commit e9eff3a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion inc/integrations.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,4 @@
/**
* Admin Dashboard logic.
*/
require trailingslashit( get_template_directory() ) . 'inc/admin/admin.php'; // phpcs:ignore
require_once trailingslashit( get_template_directory() ) . 'inc/admin/admin.php'; // phpcs:ignore
12 changes: 9 additions & 3 deletions inc/required-plugins/class-tgm-plugin-activation.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* or theme author for support.
*
* @package TGM-Plugin-Activation
* @version 2.6.3 enhanced by Pixelgrade
* @version 2.6.4 for Boilerplate
* @link http://tgmpluginactivation.com/
* @author Thomas Griffin, Gary Jones, Juliette Reinders Folmer
* @copyright Copyright (c) 2011, Thomas Griffin
Expand Down Expand Up @@ -55,7 +55,7 @@ class TGM_Plugin_Activation {
*
* @const string Version number.
*/
const TGMPA_VERSION = '2.6.3'; // Version bump by Pixelgrade!!!
const TGMPA_VERSION = '2.6.4'; // Version bump by Pixelgrade!!!

/**
* Regular expression to test if a URL is a WP plugin repo URL.
Expand Down Expand Up @@ -1023,6 +1023,12 @@ public function notices() {
return;
}

// Pixelgrade addition!!!
// Allow others to prevent notices.
if ( ! apply_filters( 'tgmpa_show_admin_notices', true ) ) {
return;
}

// Store for the plugin slugs by message type.
$message = array();

Expand Down Expand Up @@ -1333,7 +1339,7 @@ public function register( $plugin ) {
* @param string $plugin_slug
*/
public function deregister( $plugin_slug ) {
if ( empty( $plugin_slug ) || ! is_string( $plugin_slug ) || isset( $this->plugins[ $plugin_slug ] ) ) {
if ( empty( $plugin_slug ) || ! is_string( $plugin_slug ) || ! isset( $this->plugins[ $plugin_slug ] ) ) {
return;
}

Expand Down

0 comments on commit e9eff3a

Please sign in to comment.