Rename NOPAQUE_STORAGE to DATA_DIR

This commit is contained in:
Stephan Porada 2020-10-08 15:34:28 +02:00
parent 51306cf530
commit 99a8ea98e2

View File

@ -254,7 +254,7 @@ def add_query_result():
db.session.add(query_result) db.session.add(query_result)
db.session.commit() db.session.commit()
# create paths to save the uploaded json file # create paths to save the uploaded json file
query_result_dir = os.path.join(current_app.config['NOPAQUE_STORAGE'], query_result_dir = os.path.join(current_app.config['DATA_DIR'],
str(current_user.id), str(current_user.id),
'query_results', 'query_results',
str(query_result.id)) str(query_result.id))
@ -329,7 +329,7 @@ def inspect_query_result(query_result_id):
prefix='inspect-display-options-form' prefix='inspect-display-options-form'
) )
query_result_file_path = os.path.join( query_result_file_path = os.path.join(
current_app.config['NOPAQUE_STORAGE'], current_app.config['DATA_DIR'],
str(current_user.id), str(current_user.id),
'query_results', 'query_results',
str(query_result.id), str(query_result.id),
@ -364,7 +364,7 @@ def download_query_result(query_result_id):
if not (query_result.creator == current_user if not (query_result.creator == current_user
or current_user.is_administrator()): or current_user.is_administrator()):
abort(403) abort(403)
query_result_dir = os.path.join(current_app.config['NOPAQUE_STORAGE'], query_result_dir = os.path.join(current_app.config['DATA_DIR'],
str(current_user.id), str(current_user.id),
'query_results', 'query_results',
str(query_result.id)) str(query_result.id))