401 ) ); } return true; } public static function client_access_check( WP_REST_Request $request ) { $nonce = $request->get_header( 'X-WP-Nonce' ); if ( ! wp_verify_nonce( $nonce, 'wp_rest' ) ) { return new WP_Error( 'rest_forbidden', esc_html__( 'You are not allowed to do that', 'accept-stripe-for-contact-form-7' ), array( 'status' => 403 ) ); } return true; } public static function is_pro() { return cf7pa_fs()->can_use_premium_code(); } }