Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/passman.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrantje <brantje@gmail.com>2017-06-14 00:28:17 +0300
committerbrantje <brantje@gmail.com>2017-06-14 00:28:17 +0300
commit675abec7a5bc0bfefff9b52a54a814bd65107bb4 (patch)
treefff71bf2e28f1c892399e2e4000ed2f9e0ecdf21
parent888d699d8c2894023eab7362120a92452e37b811 (diff)
Check if variable exists before comparing. Fixes #316
-rw-r--r--js/app/controllers/share.js2
-rw-r--r--templates/views/partials/forms/share_credential/basics.html2
2 files changed, 2 insertions, 2 deletions
diff --git a/js/app/controllers/share.js b/js/app/controllers/share.js
index 0d9e166f..861020ed 100644
--- a/js/app/controllers/share.js
+++ b/js/app/controllers/share.js
@@ -216,7 +216,7 @@
};
var found = false;
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;
}
}
diff --git a/templates/views/partials/forms/share_credential/basics.html b/templates/views/partials/forms/share_credential/basics.html
index f3142d25..8774998d 100644
--- a/templates/views/partials/forms/share_credential/basics.html
+++ b/templates/views/partials/forms/share_credential/basics.html
@@ -17,7 +17,7 @@
<td>
<button class="button"
- ng-click="shareWith(inputSharedWith, selectedAccessLevel)">
+ ng-click="shareWith(inputSharedWith)">
+
</button>
</td>