Skip to content

Commit

Permalink
Update useLogout.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
tristandostaler authored Sep 9, 2024
1 parent 537f7e2 commit 185603d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/hooks/AppWriteAPI/useLogout.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,13 @@ import useStore from '@store/cloud-auth-store';

const useLogout = () => {
const setIsAppWriteLoggedIn = useStore((state) => state.setIsAppWriteLoggedIn);
const setFileId = useStore((state) => state.setFileId);

const logout = () => {
setIsAppWriteLoggedIn(false);
setFileId(undefined);
}
return logout;
};

export default useLogout;
export default useLogout;

0 comments on commit 185603d

Please sign in to comment.