mirror of
https://gitlab.com/bashrc2/epicyon
synced 2026-10-30 17:43:44 +00:00
Check text
This commit is contained in:
1 parent
e5950d4363
commit
d4751a47c6
1 file changed
+2
-2
+2
-2
@@ -236,8 +236,8 @@ def getRSS(session, url: str, moderated: bool,
|
|||||||
try:
|
try:
|
||||||
result = session.get(url, headers=sessionHeaders, params=sessionParams)
|
result = session.get(url, headers=sessionHeaders, params=sessionParams)
|
||||||
if result:
|
if result:
|
||||||
if int(len(result) / 1024) < maxFeedSizeKb and \
|
if int(len(result.text) / 1024) < maxFeedSizeKb and \
|
||||||
not containsInvalidChars(result):
|
not containsInvalidChars(result.text):
|
||||||
return xmlStrToDict(result.text, moderated, maxPostsPerSource)
|
return xmlStrToDict(result.text, moderated, maxPostsPerSource)
|
||||||
else:
|
else:
|
||||||
print('WARN: feed is too large: ' + url)
|
print('WARN: feed is too large: ' + url)
|
||||||
|
|||||||
Reference in new issue
Block a user