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 0c51e26 commit ae47ed0
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/hooks/AppWriteAPI/useLogout.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ const useLogout = () => {
const logout = () => {
setIsAppWriteLoggedIn(false);
setFileId(undefined);
var session = account.getSession("current");
account.deleteSession(session["$id"]);
account.getSession("current").then((session) => { account.deleteSession(session["$id"]); } );
}
return logout;
};
Expand Down

0 comments on commit ae47ed0

Please sign in to comment.