summaryrefslogtreecommitdiffstats
path: root/apps/user_ldap
diff options
context:
space:
mode:
authorArthur Schiwon <blizzz@owncloud.com>2014-10-08 16:20:52 +0200
committerArthur Schiwon <blizzz@owncloud.com>2014-10-08 16:20:52 +0200
commit02985c9ec5bb4c9f79754ac696d6aec12722436d (patch)
tree0c84cd9ca96ace258838bcd056110c3a20a9c641 /apps/user_ldap
parentab3535855fef82783faae50286045b644bbf6d79 (diff)
downloadnextcloud-server-02985c9ec5bb4c9f79754ac696d6aec12722436d.tar.gz
nextcloud-server-02985c9ec5bb4c9f79754ac696d6aec12722436d.zip
smaller corrections to make scruitinizer happier, no effective changes
Diffstat (limited to 'apps/user_ldap')
-rw-r--r--apps/user_ldap/js/experiencedAdmin.js14
-rw-r--r--apps/user_ldap/js/ldapFilter.js11
-rw-r--r--apps/user_ldap/js/settings.js4
3 files changed, 16 insertions, 13 deletions
diff --git a/apps/user_ldap/js/experiencedAdmin.js b/apps/user_ldap/js/experiencedAdmin.js
index bd674a37d6c..fac8dd6470f 100644
--- a/apps/user_ldap/js/experiencedAdmin.js
+++ b/apps/user_ldap/js/experiencedAdmin.js
@@ -4,6 +4,8 @@
* See the COPYING-README file.
*/
+/* global LdapWizard */
+
/**
* controls behaviour depend on whether the admin is experienced in LDAP or not.
*
@@ -48,26 +50,26 @@ ExperiencedAdmin.prototype.isExperienced = function() {
* switches all LDAP filters from Assisted to Raw mode.
*/
ExperiencedAdmin.prototype.enableRawMode = function() {
- containers = {
+ var containers = {
'toggleRawGroupFilter': '#rawGroupFilterContainer',
'toggleRawLoginFilter': '#rawLoginFilterContainer',
'toggleRawUserFilter' : '#rawUserFilterContainer'
};
- for(method in containers) {
+ for(var method in containers) {
if($(containers[method]).hasClass('invisible')) {
this.wizard[method]();
}
- };
+ }
};
ExperiencedAdmin.prototype.updateUserTab = function(mode) {
this._updateTab(mode, $('#ldap_user_count'));
-}
+};
ExperiencedAdmin.prototype.updateGroupTab = function(mode) {
this._updateTab(mode, $('#ldap_group_count'));
-}
+};
ExperiencedAdmin.prototype._updateTab = function(mode, $countEl) {
if(mode === LdapWizard.filterModeAssisted) {
@@ -77,7 +79,7 @@ ExperiencedAdmin.prototype._updateTab = function(mode, $countEl) {
} else {
$countEl.addClass('hidden');
}
-}
+};
/**
* hide user and group counters, they will be displayed on demand only
diff --git a/apps/user_ldap/js/ldapFilter.js b/apps/user_ldap/js/ldapFilter.js
index 2d3ca8b3691..5b93d81f371 100644
--- a/apps/user_ldap/js/ldapFilter.js
+++ b/apps/user_ldap/js/ldapFilter.js
@@ -1,6 +1,6 @@
/* global LdapWizard */
-function LdapFilter(target, determineModeCallback) {
+function LdapFilter(target, determineModeCallback) {
this.locked = true;
this.target = false;
this.mode = LdapWizard.filterModeAssisted;
@@ -14,7 +14,7 @@ function LdapFilter(target, determineModeCallback) {
target === 'Group') {
this.target = target;
}
-}
+};
LdapFilter.prototype.activate = function() {
if(this.activated) {
@@ -23,7 +23,7 @@ LdapFilter.prototype.activate = function() {
this.activated = true;
this.determineMode();
-}
+};
LdapFilter.prototype.compose = function(callback) {
var action;
@@ -111,11 +111,11 @@ LdapFilter.prototype.setMode = function(mode) {
if(mode === LdapWizard.filterModeAssisted || mode === LdapWizard.filterModeRaw) {
this.mode = mode;
}
-}
+};
LdapFilter.prototype.getMode = function() {
return this.mode;
-}
+};
LdapFilter.prototype.unlock = function() {
this.locked = false;
@@ -129,6 +129,7 @@ LdapFilter.prototype.findFeatures = function() {
//TODO: reset this.foundFeatures when any base DN changes
if(!this.foundFeatures && !this.locked && this.mode === LdapWizard.filterModeAssisted) {
this.foundFeatures = true;
+ var objcEl, avgrEl;
if(this.target === 'User') {
objcEl = 'ldap_userfilter_objectclass';
avgrEl = 'ldap_userfilter_groups';
diff --git a/apps/user_ldap/js/settings.js b/apps/user_ldap/js/settings.js
index 04b4b91d1f1..f5b8081497f 100644
--- a/apps/user_ldap/js/settings.js
+++ b/apps/user_ldap/js/settings.js
@@ -694,8 +694,8 @@ var LdapWizard = {
values = values + "\n" + resultObj[i].value;
}
LdapWizard._save($('#'+originalObj)[0], $.trim(values));
- if(originalObj == 'ldap_userfilter_objectclass'
- || originalObj == 'ldap_userfilter_groups') {
+ if(originalObj === 'ldap_userfilter_objectclass'
+ || originalObj === 'ldap_userfilter_groups') {
LdapWizard.userFilter.compose(LdapWizard.detectEmailAttribute);
//when user filter is changed afterwards, login filter needs to
//be adjusted, too