[tor-commits] [lego/master] Clean up and update xml stream plugin
hiro at torproject.org
hiro at torproject.org
Wed Sep 4 12:45:22 UTC 2019
commit 62b25f1cba4a7af931ccd8f4420d0669812db09c
Author: hiro <hiro at torproject.org>
Date: Wed Sep 4 14:45:18 2019 +0200
Clean up and update xml stream plugin
---
packages/xml-to-html/lektor_xml_to_html.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/packages/xml-to-html/lektor_xml_to_html.py b/packages/xml-to-html/lektor_xml_to_html.py
index a98541d..dbffae5 100644
--- a/packages/xml-to-html/lektor_xml_to_html.py
+++ b/packages/xml-to-html/lektor_xml_to_html.py
@@ -17,8 +17,8 @@ class XmlToHtmlPlugin(Plugin):
def on_setup_env(self, **extra):
- def stream(identifier=None, url=None):
- webFile = request.urlopen("https://blog.torproject.org/events.xml")
+ def stream(url=None):
+ webFile = request.urlopen(url)
content = webFile.read()
root = etree.fromstring(content)
items = root.findall('channel/item')
More information about the tor-commits
mailing list