diff --git a/mailman_api.py b/mailman_api.py index a7256d3..59f0658 100644 --- a/mailman_api.py +++ b/mailman_api.py @@ -87,7 +87,7 @@ def list_lists(): return jsonify({'lists': lists}) -@app.route('/', method='PUT') +@app.route('/', methods=['PUT']) def subscribe(list_name): """ Adds a new subscriber to the list called 'list_name' @@ -121,7 +121,7 @@ def subscribe(list_name): return jsonify(True) -@app.route('/', method='DELETE') +@app.route('/', methods=['DELETE']) def unsubscribe(list_name): """ Unsubsribe an email address from the mailing list.