Skip to content

Commit 1d5e73a

Browse files
authored
Merge branch 'master' into fix/multiple-custom-fields
2 parents 6d31456 + 8def9ee commit 1d5e73a

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

modules/custom-status/custom-status.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -289,9 +289,14 @@ function action_admin_enqueue_scripts() {
289289

290290
// Load block editor assets and return early.
291291
if ( $this->is_block_editor() ) {
292+
global $post;
293+
292294
wp_enqueue_style( 'edit-flow-block-custom-status-styles', EDIT_FLOW_URL . 'blocks/dist/custom-status.editor.build.css', false, EDIT_FLOW_VERSION );
293295
wp_enqueue_script( 'edit-flow-block-custom-status-script', EDIT_FLOW_URL . 'blocks/dist/custom-status.build.js', array( 'wp-blocks', 'wp-element', 'wp-edit-post', 'wp-plugins', 'wp-components' ), EDIT_FLOW_VERSION );
294-
wp_localize_script( 'edit-flow-block-custom-status-script', 'EditFlowCustomStatuses', array_values( $this->get_custom_statuses() ) );
296+
297+
$custom_statuses = apply_filters( 'ef_custom_status_list', $this->get_custom_statuses(), $post );
298+
299+
wp_localize_script( 'edit-flow-block-custom-status-script', 'EditFlowCustomStatuses', array_values( $custom_statuses ) );
295300
return;
296301
}
297302

0 commit comments

Comments
 (0)