Verified Commit bcaead8a authored by Jakob Moser's avatar Jakob Moser
Browse files

Use more general resolution detection (like in old script)

parent 5dab8eba
Loading
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -33,7 +33,12 @@ def _keep_only_resolutions(content: Pandoc, strict: bool = True) -> Pandoc | Non
            ):
                # Heading introduces the agenda, so we start deleting now (including this heading)
                is_document_start = False
            case Header(_, _, text) if _starts_with(text, Str("Finanzbeschluss:")):
            case Header(_, _, text) if (
                "beschluss:"
                in " ".join(
                    child[0] for child in text if isinstance(child, Str)
                ).lower()
            ):
                is_resolution = True
            case Header():
                # Any other header means this new section is not a resolution