mirror of
https://github.com/nextcloud/passman.git
synced 2025-10-10 05:25:51 +08:00
Check if variable exists before comparing. Fixes #316
This commit is contained in:
parent
888d699d8c
commit
675abec7a5
2 changed files with 2 additions and 2 deletions
|
@ -216,7 +216,7 @@
|
||||||
};
|
};
|
||||||
var found = false;
|
var found = false;
|
||||||
for (var z = 0; z < $scope.share_settings.credentialSharedWithUserAndGroup.length; z++) {
|
for (var z = 0; z < $scope.share_settings.credentialSharedWithUserAndGroup.length; z++) {
|
||||||
if ($scope.share_settings.credentialSharedWithUserAndGroup[z].userId === shareWith[z].uid) {
|
if (shareWith[z] && $scope.share_settings.credentialSharedWithUserAndGroup[z].userId === shareWith[z].uid) {
|
||||||
found = true;
|
found = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
|
|
||||||
<td>
|
<td>
|
||||||
<button class="button"
|
<button class="button"
|
||||||
ng-click="shareWith(inputSharedWith, selectedAccessLevel)">
|
ng-click="shareWith(inputSharedWith)">
|
||||||
+
|
+
|
||||||
</button>
|
</button>
|
||||||
</td>
|
</td>
|
||||||
|
|
Loading…
Add table
Reference in a new issue