Commit c70bebd3 authored by Raniere Silva's avatar Raniere Silva
Browse files

Merge pull request #228 from r-gaia-cs/core-fix-gloss-check

Fix check of glossary item
parents e8e144be 45dbfcdc
Loading
Loading
Loading
Loading
+8 −18
Original line number Diff line number Diff line
@@ -565,8 +565,7 @@ class ReferencePageValidator(MarkdownValidator):

        entry_is_valid = True
        for line_index, line in enumerate(glossary_entry):
            if line_index == 1:
                if not re.match("^:   ", line):
            if line_index == 1 and not re.match("^:   ", line):
                logging.error(
                    "In {0}: "
                    "At glossary entry '{1}' "
@@ -574,15 +573,6 @@ class ReferencePageValidator(MarkdownValidator):
                    "start with ':    '.".format(
                        self.filename, glossary_keyword))
                entry_is_valid = False
            elif line_index > 1:
                if not re.match("^    ", line):
                    logging.error(
                        "In {0}: "
                        "At glossary entry '{1}' "
                        "Subsequent lines of definition must "
                        "start with '     '.".format(
                            self.filename,  glossary_keyword, ))
                    entry_is_valid = False
        return entry_is_valid

    def _validate_glossary(self):