Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Commit e7c77a8

Browse files
author
David Robertson
authored
Correct annotation of _iterate_over_text (#12860)
1 parent 81d9f2a commit e7c77a8

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

Diff for: changelog.d/12860.misc

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Correct a type annotation in the URL preview source code.

Diff for: synapse/rest/media/v1/preview_html.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ def parse_html_description(tree: "etree.Element") -> Optional[str]:
281281

282282

283283
def _iterate_over_text(
284-
tree: "etree.Element", *tags_to_ignore: Iterable[Union[str, "etree.Comment"]]
284+
tree: "etree.Element", *tags_to_ignore: Union[str, "etree.Comment"]
285285
) -> Generator[str, None, None]:
286286
"""Iterate over the tree returning text nodes in a depth first fashion,
287287
skipping text nodes inside certain tags.

0 commit comments

Comments
 (0)