From 37b4e144a933f0d57dca9d6349f0258f7b90253f Mon Sep 17 00:00:00 2001 From: pictuga Date: Sat, 21 Mar 2020 23:30:18 +0100 Subject: [PATCH] morss: small fixes Includes dropping off ftp support --- morss/morss.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/morss/morss.py b/morss/morss.py index ff80466..7bfc582 100644 --- a/morss/morss.py +++ b/morss/morss.py @@ -45,7 +45,7 @@ THREADS = 10 # number of threads (1 for single-threaded) DEBUG = False PORT = 8080 -PROTOCOL = ['http', 'https', 'ftp'] +PROTOCOL = ['http', 'https'] def filterOptions(options): @@ -328,7 +328,6 @@ def FeedFetch(url, options): if options.items: # using custom rules rss = feeds.FeedHTML(xml) - feed.rule rss.rules['items'] = options.items @@ -568,12 +567,12 @@ def middleware(func): def app_builder(app): # This is called when doing app = cgi_wrapper(app) - def app_wrapp(environ, start_response): + def app_wrap(environ, start_response): # This is called when a http request is being processed return func(environ, start_response, app) - return app_wrapp + return app_wrap return app_builder @@ -695,7 +694,7 @@ def main(): app = cgi_error_handler(app) app = cgi_encode(app) - print('Serving http://localhost:%s/'%port) + print('Serving http://localhost:%s/' % port) httpd = wsgiref.simple_server.make_server('', port, app) httpd.serve_forever()