Archived
1
0

Fixed a bug in which faq/community/etc pages had way too much whitespace.

This commit is contained in:
Dan Helfman 2009-03-20 17:25:30 -07:00
parent 1021a01e6a
commit ab303ea0ac
3 changed files with 8 additions and 2 deletions

3
NEWS
View File

@ -1,3 +1,6 @@
1.6.11:
*
1.6.10: March 20, 2009
* Faster uploads and downloads for users of luminotes.com.
* Luminotes Server improvements:

View File

@ -1,2 +1,2 @@
VERSION = u"1.6.10"
VERSION = u"1.6.11"
TRIAL = False

View File

@ -162,10 +162,13 @@ def fix_note_contents( contents, notebook_id, note_ids, settings ):
LINK_PATTERN = re.compile( '(<a\s+href=")([^"]+note_id=)([^"]*)("[^>]*>)(.*?)(</a>)' )
TITLE_PATTERN = re.compile( ' title="(.*?)"' )
WHITESPACE_BETWEEN_TAGS_PATTERN = re.compile( '>\s+<' )
# plug in the notebook id and support email address where appropriate
contents = contents.replace( "%s", notebook_id )
contents = contents.replace( "%s", notebook_id ).replace( "\n", " " )
contents = contents.replace( "support@luminotes.com", settings[ u"global" ].get( u"luminotes.support_email", u"" ) )
contents = WHITESPACE_BETWEEN_TAGS_PATTERN.sub( "><", contents )
contents = contents.replace( "<p> ", "<p>" )
# stitch together note links to use the actual note ids of the referenced notes.
# also, use the https URL for certain links if one is configured