Commit 6c2081b7 authored by Markus Scheidgen's avatar Markus Scheidgen
Browse files

API send files without cache.

parent e818d0a0
......@@ -70,6 +70,7 @@ class ArchiveCalcLogResource(Resource):
upload_files.archive_log_file(calc_id, 'rb'),
mimetype='text/plain',
as_attachment=True,
cache_timeout=0,
attachment_filename='%s.log' % archive_id)
except Restricted:
abort(401, message='Not authorized to access %s/%s.' % (upload_id, calc_id))
......@@ -105,6 +106,7 @@ class ArchiveCalcResource(Resource):
upload_file.archive_file(calc_id, 'rb'),
mimetype='application/json',
as_attachment=True,
cache_timeout=0,
attachment_filename='%s.json' % archive_id)
except Restricted:
abort(401, message='Not authorized to access %s/%s.' % (upload_id, calc_id))
......
......@@ -149,6 +149,7 @@ def get_raw_file_from_upload_path(
raw_file_view,
mimetype=mime_type,
as_attachment=True,
cache_timeout=0,
attachment_filename=os.path.basename(upload_filepath))
except Restricted:
abort(401, message='Not authorized to access all files in %s.' % upload_files.upload_id)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment