TagSpaces is an offline, open source, document manager with tagging support
Opening a location without sub-folder in the location manager crashes the app
sytolk2ca99fe7d042
diff --git a/src/renderer/components/DirectoryTreeView.tsx b/src/renderer/components/DirectoryTreeView.tsxindex 2231edf41..69f1b0dfb 100644--- a/src/renderer/components/DirectoryTreeView.tsx+++ b/src/renderer/components/DirectoryTreeView.tsx@@ -34,7 +34,7 @@ import { NativeTypes } from 'react-dnd-html5-backend';import { useSelector } from 'react-redux';interface Props {- classes: any;+ //classes: any;location: CommonLocation;//data?: any;handleFileMoveDrop: (item, monitor) => void;@@ -49,7 +49,7 @@ export interface DirectoryTreeViewRef {const DirectoryTreeView = forwardRef((props: Props, ref: Ref<DirectoryTreeViewRef>) => {const theme = useTheme();- const { classes, location, handleFileMoveDrop } = props;+ const { location, handleFileMoveDrop } = props;const { openDirectory } = useDirectoryContentContext();const { findLocation, changeLocation, getLocationPath } =useCurrentLocationContext();@@ -84,7 +84,7 @@ const DirectoryTreeView = forwardRef(return (<TargetFileBoxaccepts={[FILE]}- directoryPath={props.location.path}+ directoryPath={location.path}locationId={location.uuid}><CustomDragLayer />diff --git a/src/renderer/components/LocationView.tsx b/src/renderer/components/LocationView.tsxindex 0269a6fb7..7425f4102 100644--- a/src/renderer/components/LocationView.tsx+++ b/src/renderer/components/LocationView.tsx@@ -27,7 +27,7 @@ import CustomDragLayer from '-/components/CustomDragLayer';import DirectoryTreeView, {DirectoryTreeViewRef,} from '-/components/DirectoryTreeView';-import { SidePanel, classes } from '-/components/SidePanels.css';+import { SidePanel } from '-/components/SidePanels.css';import TargetFileBox from '-/components/TargetFileBox';import Tooltip from '-/components/Tooltip';import TsIconButton from '-/components/TsIconButton';@@ -310,7 +310,6 @@ function LocationView(props: Props) {<DirectoryTreeViewkey={'tree_' + location.uuid}ref={directoryTreeRef}- classes={classes}location={location}handleFileMoveDrop={handleFileMoveDrop}/>