Fix filters
This commit is contained in:
@@ -1,7 +1,8 @@
|
||||
def echomsk_title_fix(entry):
|
||||
title = entry.get("title")
|
||||
if len(title) > 20 and title[17] == ":":
|
||||
entry.title = title[19:]
|
||||
entry["title"] = title[19:]
|
||||
print("NEW TITLE", entry["title"])
|
||||
return entry
|
||||
|
||||
|
||||
|
||||
@@ -151,6 +151,7 @@ def fetch_rss(item, rss):
|
||||
filters = item.get("filters")
|
||||
if filters:
|
||||
for filter_code in filters:
|
||||
print(f"- applying filter {filter_code}")
|
||||
if FILTERS.get(filter_code):
|
||||
entry = FILTERS[filter_code](entry)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user