1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Fixes #11758 - replace unsafe chars in menu label (#11831)

* Fixes #11758 - replace unsafe chars in menu label

* Fixes #11758 - replace unsafe chars in menu label
This commit is contained in:
Rafael Ganascim
2023-02-27 13:42:30 -03:00
committed by GitHub
parent cfa6b28ceb
commit 0744ff2fa0

View File

@ -1,5 +1,6 @@
from netbox.navigation import MenuGroup
from utilities.choices import ButtonColorChoices
from django.utils.text import slugify
__all__ = (
'PluginMenu',
@ -21,7 +22,7 @@ class PluginMenu:
@property
def name(self):
return self.label.replace(' ', '_')
return slugify(self.label)
class PluginMenuItem: