How can I modify or filter this variable in an existing class? (Mai Theme)
Sometimes it takes asking a question to find out the answer. function my_attachment_grid() { $args = [ ‘post_type’ => ‘attachment’, ]; add_filter( ‘post_query_args’, ‘my_filter’, 10, 1 ); do_grid( ‘post’, $args ); } function my_filter( $args ) { $defaults = [‘post_status’=>’inherit’]; $args = array_merge( $args, $defaults ); return $args; }