Skip to content

Commit

Permalink
Add the is_admin() checks
Browse files Browse the repository at this point in the history
  • Loading branch information
michalczaplinski committed Dec 9, 2024
1 parent 6b5b689 commit a4d5b00
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/experimental/blocks.php
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ function gutenberg_block_core_query_add_url_filtering( $query, $block ) {
function gutenberg_block_core_query_add_search_query_filtering( $query ) {

// if the query is not the main query, return
if ( ! $query->is_main_query() ) {
if ( $query->is_admin() || ! $query->is_main_query() ) {
return;
}

Expand Down

0 comments on commit a4d5b00

Please sign in to comment.