diff --git a/autoreply_editor/main.py b/autoreply_editor/main.py index 20a5e48..9cd7530 100644 --- a/autoreply_editor/main.py +++ b/autoreply_editor/main.py @@ -10,7 +10,8 @@ def index(): @app.route('/', methods=['POST']) def index_post(): - input_message = request.form['message'] + '\n' + input_message = request.form['message'] + if request.method == 'POST': with open(app.config.get("MESSAGE_FILE"), 'w') as f: f.write(str(input_message)) diff --git a/wsgi.py b/wsgi.py new file mode 100644 index 0000000..96640b0 --- /dev/null +++ b/wsgi.py @@ -0,0 +1,4 @@ +from autoreply_editor import app + +if __name__ == "__main__": + app.run()