Skip to content

Commit

Permalink
Bugfix for jedie/python-creole#5 - \"start\" values are numbers.
Browse files Browse the repository at this point in the history
  • Loading branch information
jedie committed Nov 16, 2011
1 parent e54c420 commit 660cac3
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions creole/rest2html/clean_writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
#DEBUG = True

IGNORE_ATTR = (
"class", "frame", "rules",
"start", "class", "frame", "rules",
)
IGNORE_TAGS = (
"div",
Expand Down Expand Up @@ -95,9 +95,10 @@ def starttag(self, node, tagname, suffix='\n', empty=0, **attributes):
continue

if isinstance(value, list):
parts.append('%s="%s"' % (name.lower(), self.attval(' '.join(value))))
else:
parts.append('%s="%s"' % (name.lower(), self.attval(value)))
value = ' '.join([TEXT_TYPE(x) for x in value])

part = '%s="%s"' % (name.lower(), self.attval(TEXT_TYPE(value)))
parts.append(part)

if DEBUG:
print("Tag %r - ids: %r - attributes: %r - parts: %r" % (
Expand Down

0 comments on commit 660cac3

Please sign in to comment.