Make WordPress Core

Changeset 54367


Ignore:
Timestamp:
10/03/2022 02:39:05 PM (2 years ago)
Author:
davidbaumwald
Message:

Editor: Ensure block script is enqueued, regardless of ronder_callback.

Follow-up to [54155].

Props aristath, cbravobernal.
See #56408.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-block.php

    r54155 r54367  
    267267        }
    268268
    269         if ( ! empty( $this->block_type->view_script_handles ) && empty( $this->block_type->render_callback ) ) {
     269        if ( ! empty( $this->block_type->view_script_handles ) ) {
    270270            foreach ( $this->block_type->view_script_handles as $view_script_handle ) {
    271271                wp_enqueue_script( $view_script_handle );
Note: See TracChangeset for help on using the changeset viewer.