Skip to content

Commit 05b8b56

Browse files
committed
Make HTMLClass::history signature compatible to _HTMLItem::history
_HTMLItem::history accepts 4 optional named parameters. If a template (e.g. issue.item.html) calls history with a named param and then is called in the context of creating a new issue, you get a traceback. Change HTMLClass::history to accept any named parameter so adding new named params to _HTMLItem::history doesn't require a change to HTMLClass::history.
1 parent ffa2ab7 commit 05b8b56

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

CHANGES.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,8 @@ Fixed:
125125
- Fix find() with anydbm. Using protected properties raised KeyError.
126126
Add shortcut fast return. Both changes come from rdbms_common.py's
127127
find(). (John Rouillard)
128+
- Fix traceback caused by calling history() with arguments in a
129+
non-item context.
128130

129131
Features:
130132
- issue2550522 - Add 'filter' command to command-line

roundup/cgi/templating.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -958,7 +958,7 @@ def submit(self, label=''"Submit New Entry", action="new", html_kwargs={}):
958958
'\n' + \
959959
self.input(type="hidden", name="@action", value=action)
960960

961-
def history(self):
961+
def history(self, **args):
962962
if not self.is_view_ok():
963963
return self._('[hidden]')
964964
return self._('New node - no history')

0 commit comments

Comments
 (0)