Skip to content

Commit

Permalink
change return type hint in is_in_table_cell
Browse files Browse the repository at this point in the history
  • Loading branch information
CodyInnowhere authored and CodyInnowhere committed Dec 20, 2024
1 parent 37607b7 commit 02be8b2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion trafilatura/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -464,4 +464,4 @@ def copy_attributes(dest_elem: _Element, src_elem: _Element) -> None:

def is_in_table_cell(elem: _Element) -> bool:
'''Check whether an element is in a table cell'''
return elem.xpath('//ancestor::cell')
return bool(elem.xpath('//ancestor::cell'))

0 comments on commit 02be8b2

Please sign in to comment.