summaryrefslogtreecommitdiffstats
path: root/apps/files_external/js
diff options
context:
space:
mode:
authorMichael Gapczynski <mtgap@owncloud.com>2012-12-24 13:55:37 -0500
committerMichael Gapczynski <mtgap@owncloud.com>2012-12-24 13:55:37 -0500
commita0e47a2c67f0fe5ff3ed07174e0922dae67707dc (patch)
tree284012a2af84b53795ac25644ef878b2f6d30d13 /apps/files_external/js
parent3c08d2ba23e36dbf79ea5fdabaf931bdad32b3b9 (diff)
downloadnextcloud-server-a0e47a2c67f0fe5ff3ed07174e0922dae67707dc.tar.gz
nextcloud-server-a0e47a2c67f0fe5ff3ed07174e0922dae67707dc.zip
Prevent javascript error if no value is set for the multiselect
Diffstat (limited to 'apps/files_external/js')
-rw-r--r--apps/files_external/js/settings.js7
1 files changed, 6 insertions, 1 deletions
diff --git a/apps/files_external/js/settings.js b/apps/files_external/js/settings.js
index eb74dd487f7..a3abcfebb8b 100644
--- a/apps/files_external/js/settings.js
+++ b/apps/files_external/js/settings.js
@@ -27,11 +27,16 @@ OC.MountConfig={
classOptions[$(input).data('parameter')] = $(input).val();
}
});
+ if ($('#externalStorage').data('admin') === true) {
+ var multiselect = $(tr).find('.chzn-select').val();
+ if (multiselect == null) {
+ return false;
+ }
+ }
if (addMountPoint) {
var status = false;
if ($('#externalStorage').data('admin') === true) {
var isPersonal = false;
- var multiselect = $(tr).find('.chzn-select').val();
var oldGroups = $(tr).find('.applicable').data('applicable-groups');
var oldUsers = $(tr).find('.applicable').data('applicable-users');
$.each(multiselect, function(index, value) {