1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-09-14 02:08:50 +02:00

matchValue defaults

This commit is contained in:
Kyle Spearrin 2018-03-03 22:48:51 -05:00
parent 5ef72091db
commit 84b114dc97
2 changed files with 4 additions and 13 deletions

View File

@ -17,7 +17,8 @@ angular
login: {
uris: [{
uri: null,
match: null
match: null,
matchValue: null
}]
},
identity: {},
@ -35,8 +36,6 @@ angular
angular.extend($scope.cipher, $stateParams.cipher);
}
setUriMatchValues();
$timeout(function () {
popupUtilsService.initListSectionItemListeners(document, angular);
@ -128,6 +127,7 @@ angular
$scope.cipher.login.uris.push({
uri: null,
match: null,
matchValue: null
});
$timeout(function () {
@ -193,14 +193,4 @@ angular
}
});
};
function setUriMatchValues() {
if ($scope.cipher.login && $scope.cipher.login.uris) {
for (var i = 0; i < $scope.cipher.login.uris.length; i++) {
$scope.cipher.login.uris[i].matchValue =
$scope.cipher.login.uris[i].match || $scope.cipher.login.uris[i].match === 0 ?
$scope.cipher.login.uris[i].match.toString() : '';
}
}
}
});

View File

@ -141,6 +141,7 @@ angular
$scope.cipher.login.uris.push({
uri: null,
match: null,
matchValue: null
});
$timeout(function () {