- Timestamp:
- 06/15/2021 03:21:50 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-block-styles-registry.php
r50703 r51154 44 44 45 45 if ( ! isset( $block_name ) || ! is_string( $block_name ) ) { 46 $message = __( 'Block name must be a string.' ); 47 _doing_it_wrong( __METHOD__, $message, '5.3.0' ); 46 _doing_it_wrong( 47 __METHOD__, 48 __( 'Block name must be a string.' ), 49 '5.3.0' 50 ); 48 51 return false; 49 52 } 50 53 51 54 if ( ! isset( $style_properties['name'] ) || ! is_string( $style_properties['name'] ) ) { 52 $message = __( 'Block style name must be a string.' ); 53 _doing_it_wrong( __METHOD__, $message, '5.3.0' ); 55 _doing_it_wrong( 56 __METHOD__, 57 __( 'Block style name must be a string.' ), 58 '5.3.0' 59 ); 54 60 return false; 55 61 } … … 74 80 public function unregister( $block_name, $block_style_name ) { 75 81 if ( ! $this->is_registered( $block_name, $block_style_name ) ) { 76 /* translators: 1: Block name, 2: Block style name. */ 77 $message = sprintf( __( 'Block "%1$s" does not contain a style named "%2$s".' ), $block_name, $block_style_name ); 78 _doing_it_wrong( __METHOD__, $message, '5.3.0' ); 82 _doing_it_wrong( 83 __METHOD__, 84 /* translators: 1: Block name, 2: Block style name. */ 85 sprintf( __( 'Block "%1$s" does not contain a style named "%2$s".' ), $block_name, $block_style_name ), 86 '5.3.0' 87 ); 79 88 return false; 80 89 }
Note: See TracChangeset
for help on using the changeset viewer.