mirror of
https://github.com/simon987/chan_feed.git
synced 2025-12-14 04:59:02 +00:00
monitoring tweaks + bug fixes
This commit is contained in:
@@ -15,8 +15,10 @@ class FChanHtmlChanHelper(DesuChanHtmlChanHelper):
|
||||
threads = []
|
||||
|
||||
for threadEl in soup.find_all("div", id=lambda tid: tid and re.match("thread[0-9]+", tid)):
|
||||
omit = threadEl.find("span", class_="omittedposts")
|
||||
threads.append({
|
||||
"id": int(threadEl.get("id")[6:]),
|
||||
"omit": int(omit.text.split(" ")[0]) if omit and omit.text else 0
|
||||
})
|
||||
|
||||
next_url = None
|
||||
|
||||
@@ -15,8 +15,10 @@ class TgChanHtmlChanHelper(DesuChanHtmlChanHelper):
|
||||
threads = []
|
||||
|
||||
for threadEl in soup.find_all("div", id=lambda tid: tid and tid[6:7].isdigit()):
|
||||
omit = threadEl.find("span", class_="omittedposts")
|
||||
threads.append({
|
||||
"id": int(re.search("thread([0-9]+)[a-zA-Z]*", threadEl.get("id")).group(1)),
|
||||
"omit": int(omit.text.split(" ")[0]) if omit else 0
|
||||
})
|
||||
|
||||
for form in soup.find_all("form"):
|
||||
|
||||
Reference in New Issue
Block a user