From: shamoon <4887959+shamoon@users.noreply.github.com> Date: Mon, 30 Oct 2023 23:35:42 +0000 (-0700) Subject: Fix: API statistics document_file_type_counts return type (#4464) X-Git-Tag: v2.0.0-beta.1~31 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=10929e9ac8a9bb191d15bab6d8b6b6168dcc97d9;p=thirdparty%2Fpaperless-ngx.git Fix: API statistics document_file_type_counts return type (#4464) --- diff --git a/src/documents/views.py b/src/documents/views.py index 8f2be05496..49682e3ea0 100644 --- a/src/documents/views.py +++ b/src/documents/views.py @@ -1001,7 +1001,7 @@ class StatisticsView(APIView): .annotate(mime_type_count=Count("mime_type")) .order_by("-mime_type_count") if documents_total > 0 - else 0 + else [] ) character_count = (