mirror of
https://github.com/bitwarden/web
synced 2025-12-06 00:03:28 +00:00
set profile after auth logIn
This commit is contained in:
@@ -33,10 +33,13 @@ angular
|
||||
tokenService.setToken(response.access_token);
|
||||
tokenService.setRefreshToken(response.refresh_token);
|
||||
cryptoService.setKey(key);
|
||||
if (response.EncryptedPrivateKey) {
|
||||
cryptoService.setPrivateKey(response.EncryptedPrivateKey, key);
|
||||
if (response.PrivateKey) {
|
||||
cryptoService.setPrivateKey(response.PrivateKey, key);
|
||||
}
|
||||
deferred.resolve();
|
||||
|
||||
_service.setUserProfile().then(function () {
|
||||
deferred.resolve();
|
||||
});
|
||||
}, function (error) {
|
||||
if (error.status === 400 && error.data.TwoFactorProviders && error.data.TwoFactorProviders.length) {
|
||||
deferred.resolve(error.data.TwoFactorProviders);
|
||||
|
||||
Reference in New Issue
Block a user