We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b4adb2b commit ee634d6Copy full SHA for ee634d6
2 files changed
client/src/App.jsx
@@ -49,15 +49,16 @@ const App = () => {
49
const navigate = useNavigate();
50
const currentLocation = useLocation();
51
52
- const refreshUser = () => {
+ const refreshUser = callback => {
53
me()
54
.then(user => {
55
const currentOrganization = useAppStore.getState().currentOrganization
56
const newMenuItems = menuItemsForUser(user, currentOrganization);
57
useAppStore.setState(() => ({
58
user: user,
59
menuItems: newMenuItems
60
- }))
+ }));
61
+ callback && callback();
62
})
63
}
64
0 commit comments