From b4b4e0ee69318742d94f292bb33203c86156383e Mon Sep 17 00:00:00 2001 From: Harsh Gupta <42064744+Harshg999@users.noreply.github.com> Date: Mon, 13 Jan 2025 20:08:04 +0530 Subject: [PATCH] [api] Remove unused compression field from /display API (#3955) --- apps/filebrowser/src/filebrowser/api.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/apps/filebrowser/src/filebrowser/api.py b/apps/filebrowser/src/filebrowser/api.py index 0e06cb00ef6..ebeb7bfa6f9 100644 --- a/apps/filebrowser/src/filebrowser/api.py +++ b/apps/filebrowser/src/filebrowser/api.py @@ -344,7 +344,7 @@ def display(request): return HttpResponse(f'Cannot request chunks greater than {MAX_CHUNK_SIZE_BYTES} bytes.', status=400) # Read out based on meta. - compression, offset, length, contents = read_contents(compression, path, request.fs, offset, length) + _, offset, length, contents = read_contents(compression, path, request.fs, offset, length) # Get contents as string for text mode, or at least try file_contents = None @@ -364,7 +364,6 @@ def display(request): 'length': length, 'end': offset + len(contents), 'mode': mode, - 'compression': compression, } return JsonResponse(data)