Skip to content

Default menu Modifier lacks breadcrumb param #473

Closed
Torkn opened this Issue May 22, 2010 · 1 comment

2 participants

@Torkn
Torkn commented May 22, 2010

In menus/base.py, the default Modifier class has the parameters:
modify(self, request, nodes, namespace, id, post_cut)

But the documentation, cms/docs/app_integration.txt says:
A simple modifier looks something like this::
def modify(self, request, nodes, namespace, root_id, post_cut, breadcrumb):

And in cms/menu.py:
def modify(self, request, nodes, namespace, id, post_cut, breadcrumb):

Note the additional parameter "breadcrumb".

The default modify function should have the "breadcrumb" parameter. Patch below:

diff --git a/menus/base.py b/menus/base.py
index af6fd85..ef9535f 100644
--- a/menus/base.py
+++ b/menus/base.py
@@ -17,7 +17,7 @@ class Menu(object):

 class Modifier(object):

-    def modify(self, request, nodes, namespace, id,  post_cut):
+    def modify(self, request, nodes, namespace, id,  post_cut, breadcrumb):
         pass
@ojii
ojii commented May 26, 2010

thanks for reporting, fixed in master

@christianbertschy christianbertschy pushed a commit to christianbertschy/django-cms-2.0 that referenced this issue Oct 1, 2012
Jonas Obrist fixed default menu modifier (#473) db11a23
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.