Version Description
- Fix: Only auto-apply classes on front-end. Prevents appending duplicate classes on each save.
Download this release
Release Info
Developer | helgatheviking |
Plugin | Nav Menu Roles |
Version | 1.10.1 |
Comparing to | |
See all releases |
Code changes from version 1.10.0 to 1.10.1
- nav-menu-roles.php +6 -3
- readme.txt +4 -1
nav-menu-roles.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: Nav Menu Roles
|
4 |
Plugin URI: http://www.kathyisawesome.com/449/nav-menu-roles/
|
5 |
Description: Hide custom menu items based on user roles.
|
6 |
-
Version: 1.10.
|
7 |
Author: Kathy Darling
|
8 |
Author URI: http://www.kathyisawesome.com
|
9 |
License: GPL-3.0
|
@@ -54,7 +54,7 @@ class Nav_Menu_Roles {
|
|
54 |
* @constant string version number
|
55 |
* @since 1.7.0
|
56 |
*/
|
57 |
-
CONST VERSION = '1.10.
|
58 |
|
59 |
/**
|
60 |
* Main Nav Menu Roles Instance
|
@@ -452,7 +452,10 @@ class Nav_Menu_Roles {
|
|
452 |
break;
|
453 |
}
|
454 |
|
455 |
-
|
|
|
|
|
|
|
456 |
}
|
457 |
}
|
458 |
return $menu_item;
|
3 |
Plugin Name: Nav Menu Roles
|
4 |
Plugin URI: http://www.kathyisawesome.com/449/nav-menu-roles/
|
5 |
Description: Hide custom menu items based on user roles.
|
6 |
+
Version: 1.10.1
|
7 |
Author: Kathy Darling
|
8 |
Author URI: http://www.kathyisawesome.com
|
9 |
License: GPL-3.0
|
54 |
* @constant string version number
|
55 |
* @since 1.7.0
|
56 |
*/
|
57 |
+
CONST VERSION = '1.10.1';
|
58 |
|
59 |
/**
|
60 |
* Main Nav Menu Roles Instance
|
452 |
break;
|
453 |
}
|
454 |
|
455 |
+
// Only apply classes on front-end.
|
456 |
+
if( ! is_admin() ) {
|
457 |
+
$menu_item->classes = array_unique( array_merge( $menu_item->classes, $new_classes ) );
|
458 |
+
}
|
459 |
}
|
460 |
}
|
461 |
return $menu_item;
|
readme.txt
CHANGED
@@ -5,7 +5,7 @@ Donate link: https://www.paypal.com/fundraiser/charity/1451316
|
|
5 |
Tags: menu, menus, nav menu, nav menus
|
6 |
Requires at least: 4.5.0
|
7 |
Tested up to: 5.4.0
|
8 |
-
Stable tag: 1.10.
|
9 |
License: GPLv3
|
10 |
|
11 |
Hide custom menu items based on user roles. PLEASE READ THE FAQ IF YOU ARE NOT SEEING THE SETTINGS.
|
@@ -238,6 +238,9 @@ Yes, but manually. WPML developers have informed me that the meta data for nav m
|
|
238 |
|
239 |
== Changelog ==
|
240 |
|
|
|
|
|
|
|
241 |
= 1.10.0 =
|
242 |
* Fix: My hook made it into core for WP5.4!! Can finally stop overriding the admin menu Walker.
|
243 |
|
5 |
Tags: menu, menus, nav menu, nav menus
|
6 |
Requires at least: 4.5.0
|
7 |
Tested up to: 5.4.0
|
8 |
+
Stable tag: 1.10.1
|
9 |
License: GPLv3
|
10 |
|
11 |
Hide custom menu items based on user roles. PLEASE READ THE FAQ IF YOU ARE NOT SEEING THE SETTINGS.
|
238 |
|
239 |
== Changelog ==
|
240 |
|
241 |
+
= 1.10.1 =
|
242 |
+
* Fix: Only auto-apply classes on front-end. Prevents appending duplicate classes on each save.
|
243 |
+
|
244 |
= 1.10.0 =
|
245 |
* Fix: My hook made it into core for WP5.4!! Can finally stop overriding the admin menu Walker.
|
246 |
|