X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/d0611f387f0ec0163fc8f6053a7715bc3d592700..44821dc84765936ce99fa2d760ef683281f0a578:/src/store/auth/auth-reducer.ts?ds=sidebyside diff --git a/src/store/auth/auth-reducer.ts b/src/store/auth/auth-reducer.ts index ce836a55..c109acaf 100644 --- a/src/store/auth/auth-reducer.ts +++ b/src/store/auth/auth-reducer.ts @@ -79,12 +79,12 @@ export const authReducer = (services: ServiceRepository) => (state = initialStat apiToken: token, apiTokenExpiration: tokenExpiration, apiTokenLocation: tokenLocation, - homeCluster: user.uuid.substr(0, 5) + homeCluster: user.uuid.substring(0, 5) }), LOGIN: () => state, LOGOUT: () => ({ ...state, apiToken: undefined }), USER_DETAILS_SUCCESS: (user: User) => - ({ ...state, user, homeCluster: user.uuid.substr(0, 5) }), + ({ ...state, user, homeCluster: user.uuid.substring(0, 5) }), SET_SSH_KEYS: (sshKeys: SshKeyResource[]) => ({ ...state, sshKeys }), ADD_SSH_KEY: (sshKey: SshKeyResource) => ({ ...state, sshKeys: state.sshKeys.concat(sshKey) }),