We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent becd2d1 commit 385eef7Copy full SHA for 385eef7
src/components/LeftDrawerOrg/LeftDrawerOrg.tsx
@@ -43,6 +43,7 @@ const leftDrawerOrg = ({
43
const { getItem } = useLocalStorage();
44
const userId = getItem('id');
45
const getIdFromPath = (pathname: string): string => {
46
+ if (!pathname) return '';
47
const segments = pathname.split('/');
48
// Index 2 represents the ID in paths like /member/{userId}
49
return segments.length > 2 ? segments[2] : '';
@@ -82,7 +83,7 @@ const leftDrawerOrg = ({
82
83
return () => {
84
isMounted = false;
85
};
- }, [data, location]);
86
+ }, [data]);
87
88
/**
89
* Handles link click to hide the drawer on smaller screens.
0 commit comments