def _get_title(self, markdown_content: str) -> (str or None):
    headings_found = re.search('^\\#{1,6}\\s+(.+?)(?:\\s+\\{\\#\\S+\\})?\\s*$', markdown_content, flags=re.MULTILINE)
    if headings_found:
        return headings_found.group(1)
    return None
def _get_title(self, markdown_content: str) -> (str or None):
    headings_found = re.search('^\\#{1,6}\\s+(.+?)(?:\\s+\\{\\#\\S+\\})?\\s*$', markdown_content, flags=re.MULTILINE)
    if headings_found:
        return headings_found.group(1)
    return None