From 59cd922a53313217a9c31d3430adba79deb88e3a Mon Sep 17 00:00:00 2001 From: Ethan Dalool Date: Sat, 17 Feb 2018 14:59:02 -0800 Subject: [PATCH] Remove unnecessary methods=GET. --- .../etiquette_flask/endpoints/photo_endpoints.py | 4 ++-- .../etiquette_flask/endpoints/user_endpoints.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/frontends/etiquette_flask/etiquette_flask/endpoints/photo_endpoints.py b/frontends/etiquette_flask/etiquette_flask/endpoints/photo_endpoints.py index 83d276c..a658b4d 100644 --- a/frontends/etiquette_flask/etiquette_flask/endpoints/photo_endpoints.py +++ b/frontends/etiquette_flask/etiquette_flask/endpoints/photo_endpoints.py @@ -15,14 +15,14 @@ session_manager = common.session_manager # Individual photos ################################################################################ -@site.route('/photo/', methods=['GET']) +@site.route('/photo/') @session_manager.give_token def get_photo_html(photo_id): photo = common.P_photo(photo_id, response_type='html') session = session_manager.get(request) return flask.render_template('photo.html', photo=photo, session=session) -@site.route('/photo/.json', methods=['GET']) +@site.route('/photo/.json') @session_manager.give_token def get_photo_json(photo_id): photo = common.P_photo(photo_id, response_type='json') diff --git a/frontends/etiquette_flask/etiquette_flask/endpoints/user_endpoints.py b/frontends/etiquette_flask/etiquette_flask/endpoints/user_endpoints.py index f9db6c2..e879567 100644 --- a/frontends/etiquette_flask/etiquette_flask/endpoints/user_endpoints.py +++ b/frontends/etiquette_flask/etiquette_flask/endpoints/user_endpoints.py @@ -13,14 +13,14 @@ session_manager = common.session_manager # Individual users ################################################################################# -@site.route('/user/', methods=['GET']) +@site.route('/user/') @session_manager.give_token def get_user_html(username): user = common.P_user(username, response_type='html') session = session_manager.get(request) return flask.render_template('user.html', user=user, session=session) -@site.route('/user/.json', methods=['GET']) +@site.route('/user/.json') @session_manager.give_token def get_user_json(username): user = common.P_user(username, response_type='json')