Skip to content

Commit

Permalink
Switch back from session to local (#3675)
Browse files Browse the repository at this point in the history
  • Loading branch information
sdess09 authored Sep 28, 2023
1 parent cff68bb commit e0c2a6d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dashboard/src/shared/Context.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -116,12 +116,12 @@ class ContextProvider extends Component<PropsType, StateType> {
currentProject: null,
setCurrentProject: (currentProject: ProjectType, callback?: any) => {
if (currentProject) {
sessionStorage.setItem("currentProject", currentProject.id.toString());
localStorage.setItem("currentProject", currentProject.id.toString());
pushQueryParams(this.props, {
project_id: currentProject.id.toString(),
});
} else {
sessionStorage.removeItem("currentProject");
localStorage.removeItem("currentProject");
}
this.setState({ currentProject }, () => {
callback && callback();
Expand Down

0 comments on commit e0c2a6d

Please sign in to comment.