Skip to content

Commit f142038

Browse files
committed
Merge branch 'develop' into filip/revert-old-onboarding
2 parents af1badf + ba8e407 commit f142038

File tree

3 files changed

+16
-1
lines changed

3 files changed

+16
-1
lines changed

classes/admin/class-page.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,8 @@ public function add_page() {
104104
'manage_options',
105105
$page_identifier,
106106
'__return_empty_string',
107-
\progress_planner()->get_ui__branding()->get_admin_menu_icon()
107+
\progress_planner()->get_ui__branding()->get_admin_menu_icon(),
108+
\progress_planner()->get_ui__branding()->get_admin_submenu_position()
108109
);
109110

110111
\add_submenu_page(

classes/ui/class-branding.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,19 @@ public function get_admin_submenu_name(): string {
184184
: $this->get_api_data()['admin_submenu_name'];
185185
}
186186

187+
/**
188+
* Get the admin-submenu position.
189+
*
190+
* @return int|null
191+
*/
192+
public function get_admin_submenu_position(): mixed {
193+
if ( $this->get_branding_id() !== 0 && $this->get_branding_id() !== 4958 ) {
194+
return -1000;
195+
}
196+
197+
return null;
198+
}
199+
187200
/**
188201
* Get the Ravi name.
189202
*

tests/phpunit/test-class-page-types.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ public static function set_lessons_cache() {
7474
[
7575
'site' => \get_site_url(),
7676
'license_key' => \progress_planner()->get_license_key(),
77+
'locale' => apply_filters( 'prpl_lesson_locale', \get_locale() ),
7778
],
7879
$url
7980
);

0 commit comments

Comments
 (0)