PluginProbe
Jetpack – WP Security, Backup, Speed, & Growth / 10.5.3
Jetpack – WP Security, Backup, Speed, & Growth v10.5.3
12.0.3 12.1.3 12.2.3 12.3.2 12.4.2 12.5.2 12.6.4 12.7.3 12.8.3 12.9.5 13.0.2 13.1.5 13.2.4 13.3.3 13.4.5 13.5.2 13.6.2 13.7.2 13.8.3 13.9.2 14.0.1 14.1.1 14.2.2 14.3.1 14.4.2 All 500 releases
← All changes | class.jetpack-client-server.php +2 -17 12.0.310.5.3 View file →
@@ -1,11 +1,5 @@
1 -<?php // phpcs:ignore WordPress.Files.FileName.InvalidClassFileName
2 -/**
3 - * Client = Plugin
4 - * Client Server = API Methods the Plugin must respond to
5 - *
6 - * @package automattic/jetpack
7 - */
1 +<?php
8 2
9 3 use Automattic\Jetpack\Connection\Webhooks;
10 4
11 5 /**
@@ -62,15 +56,8 @@
62 56 _deprecated_function( __METHOD__, 'jetpack-9.5.0', 'Automattic\\Jetpack\\Connection\\Webhooks::handle_authorize' );
63 57 ( new Webhooks() )->handle_authorize();
64 58 }
65 59
66 - /**
67 - * Deactivate a plugin.
68 - *
69 - * @param string $probable_file Expected plugin file.
70 - * @param string $probable_title Expected plugin title.
71 - * @return int 1 if a plugin was deactivated, 0 if not.
72 - */
73 60 public static function deactivate_plugin( $probable_file, $probable_title ) {
74 61 include_once ABSPATH . 'wp-admin/includes/plugin.php';
75 62 if ( is_plugin_active( $probable_file ) ) {
76 63 deactivate_plugins( $probable_file );
@@ -79,9 +66,9 @@
79 66 // If the plugin is not in the usual place, try looking through all active plugins.
80 67 $active_plugins = Jetpack::get_active_plugins();
81 68 foreach ( $active_plugins as $plugin ) {
82 69 $data = get_plugin_data( WP_PLUGIN_DIR . '/' . $plugin );
83 - if ( $data['Name'] === $probable_title ) {
70 + if ( $data['Name'] == $probable_title ) {
84 71 deactivate_plugins( $plugin );
85 72 return 1;
86 73 }
87 74 }
@@ -90,10 +77,8 @@
90 77 return 0;
91 78 }
92 79
93 80 /**
94 - * Get the Jetpack instance.
95 - *
96 81 * @deprecated since Jetpack 9.5.0
97 82 * @see Jetpack::init()
98 83 */
99 84 public function get_jetpack() {