mirror of
https://github.com/EstrellaXD/Auto_Bangumi.git
synced 2026-12-01 00:38:13 +08:00
fix: analyser log error.
This commit is contained in:
@@ -82,16 +82,14 @@ class RSSAnalyser(TitleParser):
|
||||
|
||||
def link_to_data(self, rss: RSSItem) -> Bangumi | ResponseModel:
|
||||
torrents = self.get_rss_torrents(rss.url, False)
|
||||
try:
|
||||
for torrent in torrents:
|
||||
data = self.torrent_to_data(torrent, rss)
|
||||
if data:
|
||||
return data
|
||||
except Exception as e:
|
||||
logger.debug(e)
|
||||
return ResponseModel(
|
||||
status=False,
|
||||
status_code=406,
|
||||
msg_en="No new title has been found.",
|
||||
msg_zh="没有找到新的番剧。",
|
||||
)
|
||||
for torrent in torrents:
|
||||
data = self.torrent_to_data(torrent, rss)
|
||||
if data:
|
||||
return data
|
||||
else:
|
||||
return ResponseModel(
|
||||
status=False,
|
||||
status_code=406,
|
||||
msg_en="Cannot parse this link.",
|
||||
msg_zh="无法解析此链接。",
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user