PluginProbe
MainWP Dashboard: Self-hosted WordPress Management for Agencies / 6.2.2
MainWP Dashboard: Self-hosted WordPress Management for Agencies v6.2.2
6.2.2 6.2.1 6.2 6.1.8 6.1.7 6.1.6 6.1.5 6.1.4 6.1.3 6.1.2 6.1.1 6.1 6.0.12 6.0.11 4.6.0.1 5.0 5.0.1 5.0.2 5.0.3 5.0.3.1 5.0.3.2 5.1 5.1.1 5.2 5.2.1 All 155 releases
← All changes | mainwp.php +18 -1 6.0.11 → 6.2.2 View file →
@@ -7,9 +7,9 @@
7 7 * Author: MainWP
8 8 * Author URI: https://mainwp.com
9 9 * Plugin URI: https://mainwp.com/
10 10 * Text Domain: mainwp
11 - * Version: 6.0.11
11 + * Version: 6.2.2
12 12 * License: GPLv3 or later
13 13 * License URI: https://www.gnu.org/licenses/gpl-3.0.html
14 14 *
15 15 * @package MainWP/Dashboard
@@ -153,8 +153,21 @@
153 153 if ( class_exists( '\MainWP\Dashboard\MainWP_Abilities' ) ) {
154 154 \MainWP\Dashboard\MainWP_Abilities::init();
155 155 }
156 156
157 +if ( file_exists( MAINWP_PLUGIN_DIR . 'modules/system-monitor/bootstrap.php' ) ) {
158 + define( 'MAINWP_SYSTEM_MONITOR_FILE', __FILE__ );
159 + require_once MAINWP_PLUGIN_DIR . 'modules/system-monitor/bootstrap.php'; // NOSONAR - WP compatible.
160 + register_activation_hook(
161 + MAINWP_SYSTEM_MONITOR_FILE,
162 + array( MainWP\Dashboard\SystemMonitor\MainWP_System_Monitor::class, 'activate' )
163 + );
164 + register_deactivation_hook(
165 + MAINWP_SYSTEM_MONITOR_FILE,
166 + array( MainWP\Dashboard\SystemMonitor\MainWP_System_Monitor::class, 'deactivate' )
167 + );
168 +}
169 +
157 170 // Detect if secupress_scanner is running.
158 171 $mainwp_is_secupress_scanning = false;
159 172 if ( ! empty( $_GET ) && isset( $_GET['test'] ) && isset( $_GET['action'] ) && 'secupress_scanner' === $_GET['action'] ) { // phpcs:ignore WordPress.Security.NonceVerification,WordPress.Security.ValidatedSanitizedInput.InputNotSanitized.Recommended
160 173 $mainwp_is_secupress_scanning = true;
@@ -165,5 +178,9 @@
165 178 $mainWP = new MainWP\Dashboard\MainWP_System( WP_PLUGIN_DIR . DIRECTORY_SEPARATOR . plugin_basename( __FILE__ ) );
166 179 register_activation_hook( __FILE__, array( $mainWP, 'activation' ) );
167 180 register_deactivation_hook( __FILE__, array( $mainWP, 'deactivation' ) );
168 181 add_action( 'plugins_loaded', array( $mainWP, 'update_install' ) );
182 + // Register the post-upgrade hook for MWP-1557/1558 pk/ filename migration.
183 + // Must be registered before plugins_loaded fires so MainWP_Install::install()
184 + // sees a subscriber when it does_action('mainwp_db_after_update').
185 + add_action( 'plugins_loaded', array( 'MainWP\\Dashboard\\MainWP_Keys_Manager', 'register_migration_hooks' ), 5 );
169 186 }