diff options
author | kondou <kondou@ts.unde.re> | 2013-07-31 21:21:02 +0200 |
---|---|---|
committer | kondou <kondou@ts.unde.re> | 2013-07-31 21:21:02 +0200 |
commit | aaf0fec9f54bc6f9eef5df00441d593e053ee74b (patch) | |
tree | ca65f4c20b8d1e698d815a3b5970926023093478 /core/js/oc-dialogs.js | |
parent | 50101a85a63f29c47abe325aecb3af26bc8a96d1 (diff) | |
download | nextcloud-server-aaf0fec9f54bc6f9eef5df00441d593e053ee74b.tar.gz nextcloud-server-aaf0fec9f54bc6f9eef5df00441d593e053ee74b.zip |
Fix some JSLint warnings
Diffstat (limited to 'core/js/oc-dialogs.js')
-rw-r--r-- | core/js/oc-dialogs.js | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/core/js/oc-dialogs.js b/core/js/oc-dialogs.js index f4bc174b5eb..04fc43af001 100644 --- a/core/js/oc-dialogs.js +++ b/core/js/oc-dialogs.js @@ -79,9 +79,9 @@ var OCdialogs = { title: title }).data('path', ''); - if (modal === undefined) { modal = false }; - if (multiselect === undefined) { multiselect = false }; - if (mimetype_filter === undefined) { mimetype_filter = '' }; + if (modal === undefined) { modal = false; } + if (multiselect === undefined) { multiselect = false; } + if (mimetype_filter === undefined) { mimetype_filter = ''; } $('body').append(self.$filePicker); @@ -106,7 +106,7 @@ var OCdialogs = { datapath.push(self.$filePicker.data('path') + '/' + $(element).text()); }); } else { - var datapath = self.$filePicker.data('path'); + datapath = self.$filePicker.data('path'); datapath += '/' + self.$filelist.find('.filepicker_element_selected .filename').text(); } callback(datapath); @@ -155,7 +155,7 @@ var OCdialogs = { message: content, type: dialog_type }); - if (modal === undefined) { modal = false }; + if (modal === undefined) { modal = false; } $('body').append($dlg); var buttonlist = []; switch (buttons) { @@ -163,7 +163,7 @@ var OCdialogs = { buttonlist = [{ text: t('core', 'Yes'), click: function(){ - if (callback !== undefined) { callback(true) }; + if (callback !== undefined) { callback(true); } $(dialog_id).ocdialog('close'); }, defaultButton: true @@ -171,7 +171,7 @@ var OCdialogs = { { text: t('core', 'No'), click: function(){ - if (callback !== undefined) { callback(false) }; + if (callback !== undefined) { callback(false); } $(dialog_id).ocdialog('close'); } }]; @@ -179,7 +179,7 @@ var OCdialogs = { case OCdialogs.OK_BUTTON: var functionToCall = function() { $(dialog_id).ocdialog('close'); - if(callback !== undefined) { callback() }; + if(callback !== undefined) { callback(); } }; buttonlist[0] = { text: t('core', 'Ok'), @@ -187,7 +187,7 @@ var OCdialogs = { defaultButton: true }; break; - }; + } $(dialog_id).ocdialog({ closeOnEscape: true, @@ -269,7 +269,7 @@ var OCdialogs = { var sorted = dirs.concat(others); $.each(sorted, function(idx, entry) { - $li = self.$listTmpl.octemplate({ + var $li = self.$listTmpl.octemplate({ type: entry.type, dir: dir, filename: entry.name, @@ -287,13 +287,13 @@ var OCdialogs = { */ _fillSlug: function() { this.$dirTree.empty(); - var self = this + var self = this; var path = this.$filePicker.data('path'); var $template = $('<span data-dir="{dir}">{name}</span>'); if(path) { var paths = path.split('/'); $.each(paths, function(index, dir) { - var dir = paths.pop(); + dir = paths.pop(); if(dir === '') { return false; } @@ -327,7 +327,7 @@ var OCdialogs = { $element.toggleClass('filepicker_element_selected'); return; } else if ( $element.data('type') === 'dir' ) { - this._fillFilePicker(this.$filePicker.data('path') + '/' + $element.data('entryname')) + this._fillFilePicker(this.$filePicker.data('path') + '/' + $element.data('entryname')); } } }; |