Permalink
Browse files

Merge branch 'master' of github.com:stoneyrh/xscripts

  • Loading branch information...
2 parents a3bd891 + 1c127fd commit 00dd8ddba61bc6a707f75cb3aea9c871a5aa189d @stoneyrh committed Mar 27, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 web2py_online_book.py
@@ -110,7 +110,7 @@ def handle_starttag(self, tag, attrs):
self.__consumer = self.__article.set_title
elif self.__levels > 0:
self.__levels = self.__levels + 1
- if tag in ('p', 'ul', 'ol', 'h1', 'h2', 'h3', 'h4'):
+ if tag in ('p', 'ul', 'ol', 'h1', 'h2', 'h3', 'h4', 'code'):
self.__article.append('\n')
elif tag == 'div':
for attr, value in attrs:
@@ -133,7 +133,7 @@ def handle_endtag(self, tag):
self.__article.append(self.__consumer.content())
self.__article.append('\n')
self.__consumer = self.__article.append
- elif tag == 'li':
+ elif tag in ('li'):
self.__article.append('\n')
elif tag == 'div' and not self.__consumer:
if hasattr(self, '__last_consumer') and self.__last_consumer:

0 comments on commit 00dd8dd

Please sign in to comment.