Skip to content

Commit

Permalink
Merge pull request #118 from ItinerisLtd/postgrid-posttypes-check
Browse files Browse the repository at this point in the history
fix(PostGrid): `Argument #3 must be of type string
  • Loading branch information
codepuncher authored Aug 12, 2024
2 parents 7a04275 + 42b9691 commit 812a181
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Settings/PostGrid.php
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,7 @@ public static function filterBar($settings): string
if ('main_query' === $settings->data_source) {
$postTypes = [get_post_type()];
}
$postTypes = array_filter($postTypes);
if (empty($postTypes)) {
$postTypes = ['post'];
}
Expand Down

0 comments on commit 812a181

Please sign in to comment.