From 4fe4bb99b7184aee3e23f0fe18446f9af259ea66 Mon Sep 17 00:00:00 2001 From: Mike Cao Date: Mon, 10 Nov 2025 22:42:20 -0800 Subject: [PATCH] Apply suggestion from @greptile-apps[bot] Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> --- src/components/input/DownloadButton.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/input/DownloadButton.tsx b/src/components/input/DownloadButton.tsx index 69098501..b9e2a5f6 100644 --- a/src/components/input/DownloadButton.tsx +++ b/src/components/input/DownloadButton.tsx @@ -14,9 +14,9 @@ export function DownloadButton({ const { formatMessage, labels } = useMessages(); const handleClick = async () => { - if (!data || data.length === 0) { - return; - } + const handleClick = async () => { + downloadCsv(`${filename}.csv`, Papa.unparse(data)); + }; downloadCsv(`${filename}.csv`, Papa.unparse(data)); };