Commit 9ebe41a7 authored by Kiste's avatar Kiste
Browse files

Add WSGI

parent 10a17e88
# -*- coding: utf-8 -*-
from studfeed import generate_feed
USER = ''
PASSWORD = ''
def application(environ, start_response):
try:
feed = generate_feed(USER, PASSWORD).atom_str()
except:
start_response('500 Internal Server Error', [('Content-Type', 'text/plain')])
return []
start_response('200 OK', [('Content-Type', 'application/atom+xml'), ("Content-Length", str(len(feed))])
return [feed]
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment