1. wladislaw
  2. semanticeditor

Commits

Luke Plant  committed e1c6d01

Fixed error in error message

  • Participants
  • Parent commits 05e52c4
  • Branches default

Comments (0)

Files changed (1)

File semanticeditor/utils.py

View file
     names = {}
     for num, name in headings:
         if num > lastnum + 1:
-            raise IncorrectHeadings('Heading "%(name)s" is level H%(foundnum)d, but it should be level H%(rightnum)d or less'  % dict(name=name,foundnum=num,rightnum=lastnum))
+            raise IncorrectHeadings('Heading "%(name)s" is level H%(foundnum)d, but it should be level H%(rightnum)d or less'  % dict(name=name,foundnum=num,rightnum=lastnum+1))
         lastnum = num
         if name in names:
             raise IncorrectHeadings('There are more than one headings with the name "%s".' % name)