Skip to content
Snippets Groups Projects
Commit 68fe394c authored by Andreas Valder's avatar Andreas Valder
Browse files

request.is_json() does not exist in old flask versions if method == GET

parent 1fc468df
No related branches found
No related tags found
No related merge requests found
......@@ -390,7 +390,7 @@ def edit(prefix='', ignore=[]):
prefix = request.args['prefix']
modify('BEGIN')
changes = request.values.items()
if request.is_json:
if (request.method == 'POST') and (request.is_json):
changes = request.get_json().items()
for key, val in changes:
if key in ignore:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment