Skip to content
Snippets Groups Projects
Verified Commit 08fc3a1e authored by Jonathan Weth's avatar Jonathan Weth :keyboard:
Browse files

Remove maintain_default_data for custom menus

because custom menus are created automatically if a page is opened
parent 4df56a35
No related branches found
No related tags found
1 merge request!236Resolve "aleksis.core.models.CustomMenu.DoesNotExist: CustomMenu matching query does not exist."
Pipeline #1784 passed with warnings
......@@ -536,12 +536,6 @@ class CustomMenu(ExtensibleModel):
def __str__(self):
return self.name if self.name != "" else self.id
@classmethod
def maintain_default_data(cls):
menus = ["footer"]
for menu in menus:
cls.get_default(menu)
@classmethod
def get_default(cls, name):
menu, _ = cls.objects.get_or_create(id=name, defaults={"name": name})
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment