Skip to content

Commit

Permalink
minor change
Browse files Browse the repository at this point in the history
  • Loading branch information
ankitakinger committed Jan 17, 2025
1 parent 4f1382e commit fce6aef
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions app/client/src/pages/Editor/IDE/LeftPane/DataSidePane.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,14 +59,13 @@ const DataSidePane = (props: DataSidePaneProps) => {
const groupedDatasources = useSelector(getDatasourcesGroupedByPluginCategory);
const plugins = useSelector(getPlugins);
const groupedPlugins = keyBy(plugins, "id");
const ideType = getIDETypeByUrl(history.location.pathname);
const location = useLocation();
const ideType = getIDETypeByUrl(location.pathname);
const dsUsageMap = useSelector((state) => dsUsageSelector(state, ideType));
const goToDatasource = useCallback((id: string) => {
history.push(datasourcesEditorIdURL({ datasourceId: id }));
}, []);

const location = useLocation();

useEffect(() => {
setCurrentSelectedDatasource(getSelectedDatasourceId(location.pathname));
}, [location]);
Expand Down

0 comments on commit fce6aef

Please sign in to comment.