update rss_proxy.py
* testing fixes description
This commit is contained in:
@@ -73,7 +73,6 @@ def init_proxy(app):
|
|||||||
root = ET.fromstring(xml_data)
|
root = ET.fromstring(xml_data)
|
||||||
items = root.findall(".//item")
|
items = root.findall(".//item")
|
||||||
|
|
||||||
|
|
||||||
cached_items = []
|
cached_items = []
|
||||||
new_items = []
|
new_items = []
|
||||||
|
|
||||||
@@ -111,9 +110,9 @@ def init_proxy(app):
|
|||||||
|
|
||||||
final_items = cached_items + new_items
|
final_items = cached_items + new_items
|
||||||
response_xml = f"""{_head_html}{"".join(final_items)}</channel></rss>"""
|
response_xml = f"""{_head_html}{"".join(final_items)}</channel></rss>"""
|
||||||
|
response_xml = response_xml.replace("&", "&")
|
||||||
|
|
||||||
return Response(response_xml, content_type="application/xml; charset=utf-8")
|
return Response(response_xml, content_type="application/xml; charset=utf-8")
|
||||||
|
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
return f"Error: {e}", 500
|
return f"Error: {e}", 500
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user