Changeset 55126
- Timestamp:
- 01/24/2023 02:40:47 PM (22 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/blocks.php
r54520 r55126 1168 1168 * @since 5.8.0 1169 1169 * 1170 * @param WP_Block_Type $block_type Block type to check for support.1171 * @param array $feature Path to a specific feature to check support for.1172 * @param mixed $default 1170 * @param WP_Block_Type $block_type Block type to check for support. 1171 * @param array $feature Path to a specific feature to check support for. 1172 * @param mixed $default_value Optional. Fallback value for feature support. Default false. 1173 1173 * @return bool Whether the feature is supported. 1174 1174 */ 1175 function block_has_support( $block_type, $feature, $default = false ) {1176 $block_support = $default ;1175 function block_has_support( $block_type, $feature, $default_value = false ) { 1176 $block_support = $default_value; 1177 1177 if ( $block_type && property_exists( $block_type, 'supports' ) ) { 1178 $block_support = _wp_array_get( $block_type->supports, $feature, $default );1178 $block_support = _wp_array_get( $block_type->supports, $feature, $default_value ); 1179 1179 } 1180 1180
Note: See TracChangeset
for help on using the changeset viewer.