diff --git a/app/views.py b/app/views.py index 0f809f0..8133c38 100644 --- a/app/views.py +++ b/app/views.py @@ -77,13 +77,13 @@ class ReindexPageView(TemplateView): return HttpResponsePermanentRedirect(reverse('admin:index')) -def send_from_file(request, path): +def send_from_file(request, filename): request_for = '' if request.path.startswith('/geodata'): request_for = 'geodata' elif request.path.startswith('/data'): request_for = 'data' - file_path = ospath.join(DATA_PATH, request_for, path) + file_path = ospath.join(DATA_PATH, request_for, filename) file_to_send = open(file_path, 'rb') response = FileResponse(file_to_send) return response