Skip to content
This repository has been archived by the owner on Jan 16, 2022. It is now read-only.

Commit

Permalink
fix: remove token from AppState
Browse files Browse the repository at this point in the history
  • Loading branch information
griffithtp committed Jul 9, 2019
1 parent 6a421ab commit 78b4c3f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/App/App.tsx
Expand Up @@ -25,7 +25,6 @@ export interface AppStateInterface {
logoUrl: string;
user: {
username?: string;
token?: string;
};
scope: string;
showLoginModal: boolean;
Expand Down Expand Up @@ -133,7 +132,7 @@ export default class App extends Component<{}, AppStateInterface> {
if (username && token) {
storage.setItem('username', username);
storage.setItem('token', token);
this.setLoggedUser(username, token);
this.setLoggedUser(username);
}

if (error) {
Expand All @@ -144,7 +143,7 @@ export default class App extends Component<{}, AppStateInterface> {
}
};

public setLoggedUser = (username, token) => {
public setLoggedUser = username => {
this.setState({
user: {
username,
Expand Down

0 comments on commit 78b4c3f

Please sign in to comment.