Completed
Push — add/phone-number-block ( d1c1d9 )
by
unknown
06:52
created

phone-number.php ➔ jetpack_phone_number_block_load_assets()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 2
dl 0
loc 4
rs 10
c 0
b 0
f 0
1
<?php
2
/**
3
 * Phone Number Block.
4
 *
5
 * @since 8.x
6
 *
7
 * @package Jetpack
8
 */
9
10
jetpack_register_block(
11
	'jetpack/phone-number',
12
	array( 'render_callback' => 'jetpack_phone_number_block_load_assets' )
13
);
14
15
/**
16
 * Phone Number block registration/dependency declaration.
17
 *
18
 * @param array  $attr    Array containing the Phone Number block attributes.
19
 * @param string $content String containing the Phone Number block content.
20
 *
21
 * @return string
22
 */
23
function jetpack_phone_number_block_load_assets( $attr, $content ) {
24
	Jetpack_Gutenberg::load_assets_as_required( 'phone-number' );
25
	return $content;
26
}
27