Explorar o código

clear localstorage on logout

Sean Rhee %!s(int64=5) %!d(string=hai) anos
pai
achega
01ce60a02e
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      dashboard/src/main/Main.tsx

+ 3 - 0
dashboard/src/main/Main.tsx

@@ -55,6 +55,9 @@ export default class Main extends Component<PropsType, StateType> {
   }
   }
 
 
   handleLogOut = () => {
   handleLogOut = () => {
+    // Clears local storage for proper rendering of clusters
+    localStorage.clear();
+
     this.context.clearContext();
     this.context.clearContext();
     this.setState({ isLoggedIn: false, initialized: true });
     this.setState({ isLoggedIn: false, initialized: true });
   }
   }