Skip to content

Commit

Permalink
feat: hide Optimole menu via constant #196
Browse files Browse the repository at this point in the history
  • Loading branch information
preda-bogdan committed Dec 13, 2019
1 parent e3886eb commit e0268fa
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions inc/admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,9 @@ public function add_dns_prefetch( $hints, $relation_type ) {
* Add the dashboard page.
*/
public function add_dashboard_page() {
if ( defined( 'OPTIOMLE_HIDE_ADMIN_AREA' ) && OPTIOMLE_HIDE_ADMIN_AREA ) {
return;
}
add_media_page( 'Optimole', 'Optimole', 'manage_options', 'optimole', array( $this, 'render_dashboard_page' ) );
}

Expand Down

0 comments on commit e0268fa

Please sign in to comment.