diff options
Diffstat (limited to 'src/features/workspaces/components/WorkspaceDrawer.tsx')
-rw-r--r-- | src/features/workspaces/components/WorkspaceDrawer.tsx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/features/workspaces/components/WorkspaceDrawer.tsx b/src/features/workspaces/components/WorkspaceDrawer.tsx index bdbebdb0a..61284d81a 100644 --- a/src/features/workspaces/components/WorkspaceDrawer.tsx +++ b/src/features/workspaces/components/WorkspaceDrawer.tsx | |||
@@ -11,7 +11,6 @@ import WorkspaceDrawerItem from './WorkspaceDrawerItem'; | |||
11 | import workspaceActions from '../actions'; | 11 | import workspaceActions from '../actions'; |
12 | import { workspaceStore } from '../index'; | 12 | import { workspaceStore } from '../index'; |
13 | import { getUserWorkspacesRequest } from '../api'; | 13 | import { getUserWorkspacesRequest } from '../api'; |
14 | import Service from '../../../models/Service'; | ||
15 | import Workspace from '../models/Workspace'; | 14 | import Workspace from '../models/Workspace'; |
16 | 15 | ||
17 | const messages = defineMessages({ | 16 | const messages = defineMessages({ |
@@ -90,7 +89,7 @@ const styles = theme => ({ | |||
90 | }); | 89 | }); |
91 | 90 | ||
92 | interface IProps extends WithStylesProps<typeof styles>, WrappedComponentProps { | 91 | interface IProps extends WithStylesProps<typeof styles>, WrappedComponentProps { |
93 | getServicesForWorkspace: (workspace: Workspace | null) => Service[]; | 92 | getServicesForWorkspace: (workspace: Workspace | null) => string[]; |
94 | } | 93 | } |
95 | 94 | ||
96 | @observer | 95 | @observer |
@@ -150,7 +149,9 @@ class WorkspaceDrawer extends Component<IProps> { | |||
150 | name={workspace.name} | 149 | name={workspace.name} |
151 | isActive={actualWorkspace === workspace} | 150 | isActive={actualWorkspace === workspace} |
152 | onClick={() => { | 151 | onClick={() => { |
153 | if (actualWorkspace === workspace) return; | 152 | if (actualWorkspace === workspace) { |
153 | return; | ||
154 | } | ||
154 | workspaceActions.activate({ workspace }); | 155 | workspaceActions.activate({ workspace }); |
155 | workspaceActions.toggleWorkspaceDrawer(); | 156 | workspaceActions.toggleWorkspaceDrawer(); |
156 | }} | 157 | }} |