Skip to content

Commit 887455c

Browse files
committed
Make sure to not include draft name in the title extracted from draft text.
- Legacy-Id: 12176
1 parent 5c562ab commit 887455c

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

ietf/utils/draft.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -927,8 +927,9 @@ def get_title(self):
927927
if match:
928928
title = match.group(1)
929929
title = title.strip()
930-
title = re.sub('\s*\n\s*', ' ', title)
931-
title = re.sub(' +', ' ', title)
930+
title = re.sub(r'(?s)\n\s*\<?draft-.*$','', title)
931+
title = re.sub(r'\s*\n\s*', ' ', title)
932+
title = re.sub(r' +', ' ', title)
932933
self._title = title
933934
return self._title
934935
self.errors["title"] = "Could not find the title on the first page."

0 commit comments

Comments
 (0)