From 9ffc26db15e7b3307ce892360957ac9cc2f9b5df Mon Sep 17 00:00:00 2001 From: Christopher Usher Date: Fri, 1 Nov 2024 00:40:17 -0700 Subject: [PATCH] Added missing authentication decorators on calls that modify the templates database table --- thrimshim/thrimshim/main.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/thrimshim/thrimshim/main.py b/thrimshim/thrimshim/main.py index 0e74d83..72549f0 100644 --- a/thrimshim/thrimshim/main.py +++ b/thrimshim/thrimshim/main.py @@ -670,6 +670,7 @@ def validate_template(new_template): @app.route('/thrimshim/add-template', methods=['POST']) @request_stats +@authenticate_artist def add_template(artist=None): """Add a template to the database""" columns, message, code = validate_template(flask.request.json) @@ -700,6 +701,7 @@ def add_template(artist=None): @app.route('/thrimshim/update-template/', methods=['POST']) @request_stats +@authenticate_artist def update_template(name, artist=None): """Update a template in the database""" columns, message, code = validate_template(flask.request.json)