X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/040d25dbcc9ec46c4c21c945ccf02dcf1bf44c26..a884c545e3edad2cc2ac1210fc3148f922c155dc:/src/components/api-token/api-token.tsx?ds=sidebyside

diff --git a/src/components/api-token/api-token.tsx b/src/components/api-token/api-token.tsx
index b6616d38bf..7656bf8733 100644
--- a/src/components/api-token/api-token.tsx
+++ b/src/components/api-token/api-token.tsx
@@ -23,8 +23,10 @@ class ApiToken extends React.Component<ApiTokenProps & RouteProps & DispatchProp
         const search = this.props.location ? this.props.location.search : "";
         const apiToken = ApiToken.getUrlParameter(search, 'api_token');
         this.props.dispatch(authActions.SAVE_API_TOKEN(apiToken));
-        this.props.dispatch(authService.getUserDetails());
-        this.props.dispatch(projectService.getProjectList());
+        this.props.dispatch<any>(authService.getUserDetails()).then(() => {
+            const rootUuid = authService.getRootUuid();
+            this.props.dispatch(projectService.getProjectList(rootUuid));
+        });
     }
     render() {
         return <Redirect to="/"/>;
