Fix feeds function

This commit is contained in:
Robert Miles 2021-10-07 00:15:28 +00:00
parent 4fa770d117
commit d2b6141210
1 changed files with 1 additions and 1 deletions

2
app.py
View File

@ -181,6 +181,6 @@ def ship(request,ship=None):
@app.route("/(?P<format>rss|atom).xml")
@wrap_generator
def feeds(request,format="atom"):
with open(os.path.join("/var/gopher",format+".xml")):
with open(os.path.join("/var/gopher",format+".xml")) as f:
for line in f:
yield line.replace("gopher://cosmic.voyage/0/","gemini://cosmic.voyage/").replace("<link>gopher://cosmic.voyage","<link>gemini://cosmic.voyage")