PluginProbe
Jetpack – WP Security, Backup, Speed, & Growth / 16.3-a.1
Jetpack – WP Security, Backup, Speed, & Growth v16.3-a.1
16.3-a.3 16.3-a.1 16.2 16.2-beta 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 All 504 releases
← All changes | extensions/blocks/send-a-message/send-a-message.php +2 -5 12.2.3 → 16.3-a.1 View file →
@@ -11,11 +11,8 @@
11 11
12 12 use Automattic\Jetpack\Blocks;
13 13 use Jetpack_Gutenberg;
14 14
15 -const FEATURE_NAME = 'send-a-message';
16 -const BLOCK_NAME = 'jetpack/' . FEATURE_NAME;
17 -
18 15 /**
19 16 * Registers the block for use in Gutenberg
20 17 * This is done via an action so that we can disable
21 18 * registration if we need to.
@@ -21,9 +18,9 @@
21 18 * registration if we need to.
22 19 */
23 20 function register_block() {
24 21 Blocks::jetpack_register_block(
25 - BLOCK_NAME,
22 + __DIR__,
26 23 array(
27 24 'render_callback' => __NAMESPACE__ . '\render_block',
28 25 'plan_check' => true,
29 26 )
@@ -39,8 +36,8 @@
39 36 *
40 37 * @return string
41 38 */
42 39 function render_block( $attributes, $content ) {
43 - Jetpack_Gutenberg::load_styles_as_required( FEATURE_NAME );
40 + Jetpack_Gutenberg::load_styles_as_required( Blocks::get_block_feature( __DIR__ ) );
44 41
45 42 return $content;
46 43 }