Full Site Editing - Version 3.46566

Version Description

Download this release

Release Info

Developer mmtr86
Plugin Icon wp plugin Full Site Editing
Version 3.46566
Comparing to
See all releases

Code changes from version 3.46524 to 3.46566

build_meta.txt CHANGED
@@ -1,3 +1,3 @@
1
- commit_hash=b80a8413be16aa1b5fc8da93485187365d7a028e
2
- commit_url=https://github.com/Automattic/wp-calypso/commit/b80a8413be16aa1b5fc8da93485187365d7a028e
3
- build_number=3.46524
1
+ commit_hash=e07bdf69a5594054763b24019b540c6494d10538
2
+ commit_url=https://github.com/Automattic/wp-calypso/commit/e07bdf69a5594054763b24019b540c6494d10538
3
+ build_number=3.46566
full-site-editing-plugin.php CHANGED
@@ -2,7 +2,7 @@
2
  /**
3
  * Plugin Name: WordPress.com Editing Toolkit
4
  * Description: Enhances your page creation workflow within the Block Editor.
5
- * Version: 3.46524
6
  * Author: Automattic
7
  * Author URI: https://automattic.com/wordpress-plugins/
8
  * License: GPLv2 or later
@@ -42,7 +42,7 @@ namespace A8C\FSE;
42
  *
43
  * @var string
44
  */
45
- define( 'A8C_ETK_PLUGIN_VERSION', '3.46524' );
46
 
47
  // Always include these helper files for dotcom FSE.
48
  require_once __DIR__ . '/dotcom-fse/helpers.php';
2
  /**
3
  * Plugin Name: WordPress.com Editing Toolkit
4
  * Description: Enhances your page creation workflow within the Block Editor.
5
+ * Version: 3.46566
6
  * Author: Automattic
7
  * Author URI: https://automattic.com/wordpress-plugins/
8
  * License: GPLv2 or later
42
  *
43
  * @var string
44
  */
45
+ define( 'A8C_ETK_PLUGIN_VERSION', '3.46566' );
46
 
47
  // Always include these helper files for dotcom FSE.
48
  require_once __DIR__ . '/dotcom-fse/helpers.php';
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: automattic
3
  Tags: block, blocks, editor, gutenberg, page
4
  Requires at least: 5.5
5
  Tested up to: 6.0
6
- Stable tag: 3.46524
7
  Requires PHP: 5.6.20
8
  License: GPLv2 or later
9
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
3
  Tags: block, blocks, editor, gutenberg, page
4
  Requires at least: 5.5
5
  Tested up to: 6.0
6
+ Stable tag: 3.46566
7
  Requires PHP: 5.6.20
8
  License: GPLv2 or later
9
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
wpcom-global-styles/index.php CHANGED
@@ -144,6 +144,13 @@ function wpcom_track_global_styles( $blog_id, $post, $updated ) {
144
  // If the post isn't updated then we know the gs cpt is being created.
145
  $event_name = 'wpcom_core_global_styles_create';
146
 
 
 
 
 
 
 
 
147
  if ( $updated ) {
148
  // This is a fragile way of checking if the global styles cpt is being reset, we might need to update this condition in the future.
149
  $global_style_keys = array_keys( json_decode( $post->post_content, true ) ?? array() );
@@ -160,10 +167,10 @@ function wpcom_track_global_styles( $blog_id, $post, $updated ) {
160
 
161
  // Invoke the correct function based on the underlying infrastructure.
162
  if ( function_exists( 'wpcomsh_record_tracks_event' ) ) {
163
- wpcomsh_record_tracks_event( $event_name, array() );
164
  } else {
165
  require_lib( 'tracks/client' );
166
- tracks_record_event( get_current_user_id(), $event_name );
167
  }
168
  }
169
  add_action( 'save_post_wp_global_styles', 'wpcom_track_global_styles', 10, 3 );
144
  // If the post isn't updated then we know the gs cpt is being created.
145
  $event_name = 'wpcom_core_global_styles_create';
146
 
147
+ // These properties are for debugging purposes and should be eventually edited or removed.
148
+ $event_props = array(
149
+ 'should_limit' => (bool) wpcom_should_limit_global_styles(),
150
+ 'is_simple' => (bool) ! function_exists( 'wpcomsh_record_tracks_event' ),
151
+ 'theme' => get_stylesheet(),
152
+ );
153
+
154
  if ( $updated ) {
155
  // This is a fragile way of checking if the global styles cpt is being reset, we might need to update this condition in the future.
156
  $global_style_keys = array_keys( json_decode( $post->post_content, true ) ?? array() );
167
 
168
  // Invoke the correct function based on the underlying infrastructure.
169
  if ( function_exists( 'wpcomsh_record_tracks_event' ) ) {
170
+ wpcomsh_record_tracks_event( $event_name, $event_props );
171
  } else {
172
  require_lib( 'tracks/client' );
173
+ tracks_record_event( get_current_user_id(), $event_name, $event_props );
174
  }
175
  }
176
  add_action( 'save_post_wp_global_styles', 'wpcom_track_global_styles', 10, 3 );