fix(rp5): fix date row detection
This commit is contained in:
@@ -54,7 +54,7 @@ class RowType(Enum):
|
|||||||
def _iter_table_rows(table: Tag) -> Iterable[tuple[RowType, Tag]]:
|
def _iter_table_rows(table: Tag) -> Iterable[tuple[RowType, Tag]]:
|
||||||
for row in table.select("tr"):
|
for row in table.select("tr"):
|
||||||
title = row.select_one("td").text.strip().lower()
|
title = row.select_one("td").text.strip().lower()
|
||||||
if "сегодня" in title:
|
if "сегодня" in title or "завтра" in title:
|
||||||
yield RowType.DATE, row
|
yield RowType.DATE, row
|
||||||
elif "местное время" in title:
|
elif "местное время" in title:
|
||||||
yield RowType.TIME, row
|
yield RowType.TIME, row
|
||||||
|
|||||||
Reference in New Issue
Block a user