1
0
mirror of https://github.com/bitwarden/jslib synced 2026-01-17 07:53:50 +00:00

[bug] Use Account constructor when calling addAccount

This commit is contained in:
addison
2021-12-28 16:08:46 -05:00
parent d68c1dafaf
commit 8b901ce1b7

View File

@@ -545,7 +545,7 @@ export class AuthService implements AuthServiceAbstraction {
const accountInformation = await this.tokenService.decodeToken(tokenResponse.accessToken);
await this.stateService.addAccount(
new Account({
new Account(new Account({
profile: {
...new AccountProfile(),
...{
@@ -570,7 +570,7 @@ export class AuthService implements AuthServiceAbstraction {
refreshToken: tokenResponse.refreshToken,
},
},
})
}))
);
if (tokenResponse.twoFactorToken != null) {