Skip to content

Commit

Permalink
Remove wp_ prefix to match core
Browse files Browse the repository at this point in the history
  • Loading branch information
mkaz committed Nov 29, 2018
1 parent 9d7ad51 commit c85a6b4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
5 changes: 1 addition & 4 deletions lib/load.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,7 @@
if ( ! function_exists( 'render_block_core_categories' ) ) {
require dirname( __FILE__ ) . '/../packages/block-library/src/categories/index.php';
}
// Currently merged in core as `wp_render_block_core_latest_comments`,
// expected to change soon.
if ( ! function_exists( 'render_block_core_latest_comments' )
&& ! function_exists( 'wp_render_block_core_latest_comments' ) ) {
if ( ! function_exists( 'render_block_core_latest_comments' ) ) {
require dirname( __FILE__ ) . '/../packages/block-library/src/latest-comments/index.php';
}
if ( ! function_exists( 'render_block_core_latest_posts' ) ) {
Expand Down
4 changes: 2 additions & 2 deletions packages/block-library/src/latest-comments/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ function wp_latest_comments_draft_or_post_title( $post = 0 ) {
*
* @return string Returns the post content with latest comments added.
*/
function wp_render_block_core_latest_comments( $attributes = array() ) {
function render_block_core_latest_comments( $attributes = array() ) {
// This filter is documented in wp-includes/widgets/class-wp-widget-recent-comments.php.
$comments = get_comments(
apply_filters(
Expand Down Expand Up @@ -179,6 +179,6 @@ function wp_render_block_core_latest_comments( $attributes = array() ) {
'enum' => array( 'center', 'left', 'right', 'wide', 'full', '' ),
),
),
'render_callback' => 'wp_render_block_core_latest_comments',
'render_callback' => 'render_block_core_latest_comments',
)
);

0 comments on commit c85a6b4

Please sign in to comment.