Fix error on <a> tags without a href attribute
This commit is contained in:
parent
e0e33649a2
commit
4961042bde
|
@ -467,7 +467,7 @@ class HTMLProcessor:
|
||||||
|
|
||||||
|
|
||||||
def _matrix_to_links_add_classes(self, el: HtmlElement) -> HtmlElement:
|
def _matrix_to_links_add_classes(self, el: HtmlElement) -> HtmlElement:
|
||||||
href = unquote(el.attrib.get("href"))
|
href = unquote(el.attrib.get("href", ""))
|
||||||
|
|
||||||
if not href or not el.text:
|
if not href or not el.text:
|
||||||
return el
|
return el
|
||||||
|
|
Loading…
Reference in New Issue
Block a user