diff --git a/client/components/document/index.tsx b/client/components/document/index.tsx index d8200c86..415e31fa 100644 --- a/client/components/document/index.tsx +++ b/client/components/document/index.tsx @@ -68,7 +68,8 @@ const Document = ({ remove, editable, title, content, setTitle, setContent, init const onTitleChange = useCallback((event: ChangeEvent) => setTitle ? setTitle(event.target.value) : null, [setTitle]) - const removeFile = useCallback(() => (remove?: () => void) => { + const removeFile = useCallback((remove?: () => void) => { + console.log(remove) if (remove) { if (content && content.trim().length > 0) { const confirmed = window.confirm("Are you sure you want to remove this file?") @@ -121,7 +122,7 @@ const Document = ({ remove, editable, title, content, setTitle, setContent, init width={"100%"} id={title} /> - {remove && editable &&