From 45d9a5bc32aa5d5aa7695c4e6576f3c42f24c5c9 Mon Sep 17 00:00:00 2001 From: Sam Wilkins Date: Wed, 27 Feb 2019 17:30:10 -0500 Subject: clean up --- src/server/authentication/controllers/WorkspacesMenu.tsx | 5 ++++- src/server/authentication/controllers/user_controller.ts | 10 ---------- 2 files changed, 4 insertions(+), 11 deletions(-) (limited to 'src/server/authentication/controllers') diff --git a/src/server/authentication/controllers/WorkspacesMenu.tsx b/src/server/authentication/controllers/WorkspacesMenu.tsx index 284a8ec66..94d168a05 100644 --- a/src/server/authentication/controllers/WorkspacesMenu.tsx +++ b/src/server/authentication/controllers/WorkspacesMenu.tsx @@ -1,6 +1,6 @@ import * as React from 'react'; import * as ReactDOM from 'react-dom'; -import { observable, action, configure, reaction, computed, ObservableMap } from 'mobx'; +import { observable, action, configure, reaction, computed, ObservableMap, runInAction } from 'mobx'; import { observer } from "mobx-react"; import * as request from 'request' import './WorkspacesMenu.css' @@ -32,6 +32,9 @@ export class WorkspacesMenu extends React.Component { this.selectedWorkspaceId = newId; this.props.load(newId); this.toggle(); + // setTimeout(action(() => { + + // }), 100); } @action diff --git a/src/server/authentication/controllers/user_controller.ts b/src/server/authentication/controllers/user_controller.ts index 1f1f43684..7b89b5152 100644 --- a/src/server/authentication/controllers/user_controller.ts +++ b/src/server/authentication/controllers/user_controller.ts @@ -130,16 +130,6 @@ export let postLogin = (req: Request, res: Response, next: NextFunction) => { })(req, res, next); }; -export let getWorkspaces = (req: Request, res: Response) => { - const user: DashUserModel = req.user; - if (!user) { - return res.redirect("/login"); - } - res.render("workspace.pug", { - ids: user.allWorkspaceIds - }); -} - /** * GET /logout * Invokes the logout function on the request -- cgit v1.2.3-70-g09d2