fetch_by_collections get fields with parent 0 by default
This commit is contained in:
parent
39306fa5c3
commit
a986a4f474
|
@ -326,6 +326,10 @@ class Fields extends Repository {
|
||||||
'compare' => 'IN',
|
'compare' => 'IN',
|
||||||
);
|
);
|
||||||
|
|
||||||
|
$args = array_merge([
|
||||||
|
'parent' => 0
|
||||||
|
], $args);
|
||||||
|
|
||||||
if( isset( $args['meta_query'] ) ){
|
if( isset( $args['meta_query'] ) ){
|
||||||
$args['meta_query'][] = $meta_query;
|
$args['meta_query'][] = $meta_query;
|
||||||
} elseif(is_array($args)){
|
} elseif(is_array($args)){
|
||||||
|
|
Loading…
Reference in New Issue