Modify

Opened 18 years ago

Closed 17 years ago

#1233 closed defect (fixed)

RSS feed does not set title correctly if blog page has leading whitespace

Reported by: Alec Thomas Owned by: John Hampton
Priority: low Component: TracBlogPlugin
Severity: minor Keywords:
Cc: Trac Release: 0.10

Description

If a blog post has whitespace before the first heading, the title regex will not match. This patch works for me, YMMV.

  • blog/web_ui.py

     
    3939from tractags.api import TagEngine
    4040from tractags.parseargs import parseargs
    4141
    42 _title_split_match = re.compile(r'^=+\s+([^\n\r=]+?)\s+=+\s+(.+)$',
    43                                 re.DOTALL).match
     42_title_split_match = re.compile(r'\s*^=+\s+([^\n\r=]+?)\s+=+\s+(.+)$',
     43                                re.MULTILINE|re.DOTALL).match
    4444
    4545BOOLS_TRUE = ['true', 'yes', 'ok', 'on', 'enabled', '1']
    4646

Attachments (0)

Change History (1)

comment:1 Changed 17 years ago by John Hampton

Resolution: fixed
Status: newclosed

Patch applied in [2399]

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain John Hampton.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.