mirror of
https://github.com/bitwarden/browser.git
synced 2024-11-06 09:20:43 +01:00
resolve lint errors
This commit is contained in:
parent
715b91ab96
commit
dde20f4451
@ -13,8 +13,8 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
apiService.organizationUsers.get({ orgId: $state.params.orgId, id: id }, function (user) {
|
apiService.organizationUsers.get({ orgId: $state.params.orgId, id: id }, function (user) {
|
||||||
if (user && user.Subvaults) {
|
|
||||||
var subvaults = {};
|
var subvaults = {};
|
||||||
|
if (user && user.Subvaults) {
|
||||||
for (var i = 0; i < user.Subvaults.Data.length; i++) {
|
for (var i = 0; i < user.Subvaults.Data.length; i++) {
|
||||||
subvaults[user.Subvaults.Data[i].SubvaultId] = {
|
subvaults[user.Subvaults.Data[i].SubvaultId] = {
|
||||||
subvaultId: user.Subvaults.Data[i].SubvaultId,
|
subvaultId: user.Subvaults.Data[i].SubvaultId,
|
||||||
|
@ -87,16 +87,16 @@ angular
|
|||||||
profile.Organizations = [];
|
profile.Organizations = [];
|
||||||
}
|
}
|
||||||
|
|
||||||
var org = {
|
var o = {
|
||||||
id: org.Id,
|
id: org.Id,
|
||||||
name: org.Name,
|
name: org.Name,
|
||||||
key: org.Key,
|
key: org.Key,
|
||||||
status: org.Status
|
status: org.Status
|
||||||
};
|
};
|
||||||
profile.organizations.push(org);
|
profile.organizations.push(o);
|
||||||
|
|
||||||
_userProfile = profile;
|
_userProfile = profile;
|
||||||
cryptoService.addOrgKey(org);
|
cryptoService.addOrgKey(o);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -133,7 +133,7 @@ angular
|
|||||||
}
|
}
|
||||||
|
|
||||||
return property;
|
return property;
|
||||||
}
|
};
|
||||||
|
|
||||||
_service.encryptLogins = function (unencryptedLogins, key) {
|
_service.encryptLogins = function (unencryptedLogins, key) {
|
||||||
if (!unencryptedLogins) throw "unencryptedLogins is undefined or null";
|
if (!unencryptedLogins) throw "unencryptedLogins is undefined or null";
|
||||||
|
@ -18,7 +18,7 @@ angular
|
|||||||
try {
|
try {
|
||||||
var privateKeyBytes = _service.decrypt(privateKeyCt, key, 'raw');
|
var privateKeyBytes = _service.decrypt(privateKeyCt, key, 'raw');
|
||||||
$sessionStorage.privateKey = forge.util.encode64(privateKeyBytes);
|
$sessionStorage.privateKey = forge.util.encode64(privateKeyBytes);
|
||||||
_privateKey = forge.pki.privateKeyFromAsn1(forge.asn1.fromDer(privateKeyBytes));;
|
_privateKey = forge.pki.privateKeyFromAsn1(forge.asn1.fromDer(privateKeyBytes));
|
||||||
}
|
}
|
||||||
catch (e) {
|
catch (e) {
|
||||||
console.log('Cannot set private key. Decryption failed.');
|
console.log('Cannot set private key. Decryption failed.');
|
||||||
@ -171,7 +171,7 @@ angular
|
|||||||
}
|
}
|
||||||
|
|
||||||
return orgKeys[orgId];
|
return orgKeys[orgId];
|
||||||
}
|
};
|
||||||
|
|
||||||
_service.clearKey = function () {
|
_service.clearKey = function () {
|
||||||
_key = _b64Key = null;
|
_key = _b64Key = null;
|
||||||
|
Loading…
Reference in New Issue
Block a user