From bed2e2f2643cdd059db4828ec8faa19bdd5852a0 Mon Sep 17 00:00:00 2001 From: Djeeberjr Date: Sat, 31 Jul 2021 20:52:26 +0200 Subject: [PATCH] FileOpener dont query if ID not set --- src/components/FileOpen.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/components/FileOpen.tsx b/src/components/FileOpen.tsx index 80a18c4..dca8ded 100644 --- a/src/components/FileOpen.tsx +++ b/src/components/FileOpen.tsx @@ -14,6 +14,10 @@ interface Props { const FileOpen: React.FC = (props) => { + if (!props.id) { + return <> + } + const { data } = useGetFileQuery({ variables:{ id: props.id