@@ -577,8 +577,8 @@ def block(self, text):
577577 # tag specified on this line.
578578 if match :
579579 tag , atts , ext , cite , content = match .groups ()
580- (outer_tag , outer_atts , inner_tag , inner_atts , content ,
581- eat ) = self .fBlock (** match .groupdict ())
580+ (outer_tag , outer_atts , inner_tag , inner_atts ,
581+ content ) = self .fBlock (** match .groupdict ())
582582 inner_block = generate_tag (inner_tag , content , inner_atts )
583583 # code tags and raw text won't be indented inside outer_tag.
584584 if inner_tag != 'code' and not has_raw_text (inner_block ):
@@ -598,8 +598,8 @@ def block(self, text):
598598 line = '{0}\n {1}' .format (out .pop (), line )
599599 whitespace = ' \t \n \r \f \v '
600600 if ext or not line [0 ] in whitespace :
601- (outer_tag , outer_atts , inner_tag , inner_atts , content ,
602- eat ) = self .fBlock (tag , atts , ext , cite , line )
601+ (outer_tag , outer_atts , inner_tag , inner_atts ,
602+ content ) = self .fBlock (tag , atts , ext , cite , line )
603603 if tag == 'p' and not has_raw_text (content ):
604604 line = content
605605 else :
@@ -612,7 +612,7 @@ def block(self, text):
612612 line = self .doPBr (line )
613613 line = re .sub (r'<br>' , '<br />' , line )
614614
615- if not eat and line :
615+ if line . strip () :
616616 out .append (line )
617617
618618 if not ext :
@@ -651,8 +651,7 @@ def fBlock(self, tag, atts, ext, cite, content):
651651 # It will be empty if the regex matched and ate it.
652652 if '' == notedef :
653653 content = notedef
654- return (outer_tag , outer_atts , inner_tag , inner_atts , content ,
655- eat )
654+ return (outer_tag , outer_atts , inner_tag , inner_atts , content )
656655
657656 fns = re .search (r'fn(?P<fnid>{0}+)' .format (regex_snippets ['digit' ]),
658657 tag , flags = re .U )
@@ -728,7 +727,7 @@ def fBlock(self, tag, atts, ext, cite, content):
728727 content = self .graf (content )
729728 else :
730729 content = ''
731- return (outer_tag , outer_atts , inner_tag , inner_atts , content , eat )
730+ return (outer_tag , outer_atts , inner_tag , inner_atts , content )
732731
733732 def footnoteRef (self , text ):
734733 # somehow php-textile gets away with not capturing the space.
0 commit comments