Set WCA pages as top level in navigation if no parent exists (https://github.com/woocommerce/woocommerce-admin/pull/5456)
This commit is contained in:
parent
d8c4297e28
commit
fbdce6cd4e
|
@ -485,8 +485,8 @@ class PageController {
|
|||
'title' => $options['title'],
|
||||
'capability' => $options['capability'],
|
||||
'url' => $options['path'],
|
||||
'order' => isset( $options['order'] ) ? $options['order'] : 20,
|
||||
'is_top_level' => isset( $options['is_top_level'] ) && $options['is_top_level'],
|
||||
'order' => isset( $options['order'] ) ? $options['order'] : 100,
|
||||
'is_top_level' => ( isset( $options['is_top_level'] ) && $options['is_top_level'] ) || ! $options['parent'],
|
||||
);
|
||||
|
||||
if ( isset( $options['is_category'] ) && $options['is_category'] ) {
|
||||
|
|
Loading…
Reference in New Issue