Skip to content

Commit 812d110

Browse files
Taxonomy: Pass correct default value for $post_id to wp_terms_checklist() in the posts list table.
This matches the documented type of the `$post_id` argument and is consistent with other instances of `wp_terms_checklist()` calls. Per the function documentation, the default value is integer `0`, not `null`. Follow-up to [13535]. Props tareiking, donmhico, jrf. Fixes #43639. git-svn-id: https://develop.svn.wordpress.org/trunk@51520 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 8f3d2b4 commit 812d110

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/wp-admin/includes/class-wp-posts-list-table.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1725,7 +1725,7 @@ public function inline_edit() {
17251725
<span class="title inline-edit-categories-label"><?php echo esc_html( $taxonomy->labels->name ); ?></span>
17261726
<input type="hidden" name="<?php echo ( 'category' === $taxonomy->name ) ? 'post_category[]' : 'tax_input[' . esc_attr( $taxonomy->name ) . '][]'; ?>" value="0" />
17271727
<ul class="cat-checklist <?php echo esc_attr( $taxonomy->name ); ?>-checklist">
1728-
<?php wp_terms_checklist( null, array( 'taxonomy' => $taxonomy->name ) ); ?>
1728+
<?php wp_terms_checklist( 0, array( 'taxonomy' => $taxonomy->name ) ); ?>
17291729
</ul>
17301730

17311731
<?php endforeach; // $hierarchical_taxonomies as $taxonomy ?>

0 commit comments

Comments
 (0)