updated plugin Jetpack Protect
version 2.2.0
This commit is contained in:
@ -20,7 +20,7 @@ use Automattic\Jetpack\Status;
|
||||
*/
|
||||
class JITM {
|
||||
|
||||
const PACKAGE_VERSION = '3.1.1';
|
||||
const PACKAGE_VERSION = '3.1.11';
|
||||
|
||||
/**
|
||||
* The configuration method that is called from the jetpack-config package.
|
||||
|
@ -27,7 +27,7 @@ class Post_Connection_JITM extends JITM {
|
||||
/**
|
||||
* Tracking object.
|
||||
*
|
||||
* @var Automattic\Jetpack\Tracking
|
||||
* @var \Automattic\Jetpack\Tracking
|
||||
*
|
||||
* @access private
|
||||
*/
|
||||
@ -43,9 +43,9 @@ class Post_Connection_JITM extends JITM {
|
||||
/**
|
||||
* A special filter for WooCommerce, to set a message based on local state.
|
||||
*
|
||||
* @param string $content The current message.
|
||||
* @param object $content The current message.
|
||||
*
|
||||
* @return array The new message.
|
||||
* @return object The new message.
|
||||
*/
|
||||
public static function jitm_woocommerce_services_msg( $content ) {
|
||||
if ( ! function_exists( 'wc_get_base_location' ) ) {
|
||||
|
@ -8,6 +8,8 @@
|
||||
namespace Automattic\Jetpack\JITMS;
|
||||
|
||||
use Automattic\Jetpack\Connection\REST_Connector;
|
||||
use WP_Error;
|
||||
use WP_REST_Request;
|
||||
use WP_REST_Server;
|
||||
|
||||
/**
|
||||
@ -61,7 +63,7 @@ class Rest_Api_Endpoints {
|
||||
$query['s'] = $request['s'];
|
||||
}
|
||||
|
||||
return $jitm->get_messages( $request['message_path'], urldecode_deep( $query ), 'true' === $request['full_jp_logo_exists'] ? true : false );
|
||||
return $jitm->get_messages( $request['message_path'], urldecode_deep( $query ), 'true' === $request['full_jp_logo_exists'] );
|
||||
}
|
||||
|
||||
/**
|
||||
@ -91,6 +93,6 @@ class Rest_Api_Endpoints {
|
||||
return true;
|
||||
}
|
||||
|
||||
return new \WP_Error( 'invalid_user_permission_jetpack_delete_jitm_message', REST_Connector::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) );
|
||||
return new WP_Error( 'invalid_user_permission_jetpack_delete_jitm_message', REST_Connector::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) );
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user