Skip to content

Commit f5ca3a1

Browse files
committed
Fixed a bug in the header/footer stripping done before abstract extraction when a draft is submitted.
- Legacy-Id: 10519
1 parent b9936e1 commit f5ca3a1

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

ietf/utils/draft.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ def begpage(pages, page, newpage, line=None):
237237
if re.search("\f", line, re.I):
238238
pages, page, newpage = begpage(pages, page, newpage)
239239
continue
240-
if re.search("^ *Internet.Draft.+[12][0-9][0-9][0-9] *$", line, re.I):
240+
if re.search("^ *Internet.Draft.+ .+[12][0-9][0-9][0-9] *$", line, re.I):
241241
pages, page, newpage = begpage(pages, page, newpage, line)
242242
continue
243243
# if re.search("^ *Internet.Draft +", line, re.I):
@@ -376,9 +376,10 @@ def get_abstract(self):
376376
abstract_indent = 0
377377
look_for_header = False
378378
for line in self.lines:
379-
if not begin and abstract_re.match(line):
380-
begin=True
381-
abstract_indent = len(abstract_re.match(line).group(0))
379+
if not begin:
380+
if abstract_re.match(line):
381+
begin=True
382+
abstract_indent = len(abstract_re.match(line).group(0))
382383
continue
383384
if begin:
384385
if not line and not abstract:

0 commit comments

Comments
 (0)