diff --git a/crawler.py b/crawler.py index c31051e..7b5ea7d 100644 --- a/crawler.py +++ b/crawler.py @@ -267,7 +267,7 @@ def get_functions(elem): for child in elem.children: if child.name == "h3": if current_body != []: - out.append((current_heading, current_body)) + out.append((current_heading, sorted(current_body))) current_heading = child.text.strip() current_body = [] continue @@ -278,7 +278,7 @@ def get_functions(elem): for grandchild in child.children if grandchild.text.strip() != "" ) - out.append((current_heading, current_body)) + out.append((current_heading, sorted(current_body))) return out