From 26be62d063a40f45c4adede1550a62635a34e21e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maur=C3=ADcio=20Meneghini=20Fauth?= Date: Wed, 29 May 2019 21:02:48 -0300 Subject: [PATCH] Rename import.js variables to use camel case MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: MaurĂ­cio Meneghini Fauth --- js/import.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/js/import.js b/js/import.js index 2cec037c74..2fce4cdb75 100644 --- a/js/import.js +++ b/js/import.js @@ -13,9 +13,9 @@ function changePluginOpts () { $('#format_specific_opts').find('div.format_specific_options').each(function () { $(this).hide(); }); - var selected_plugin_name = $('#plugins').find('option:selected').val(); - $('#' + selected_plugin_name + '_options').fadeIn('slow'); - if (selected_plugin_name === 'csv') { + var selectedPluginName = $('#plugins').find('option:selected').val(); + $('#' + selectedPluginName + '_options').fadeIn('slow'); + if (selectedPluginName === 'csv') { $('#import_notification').text(Messages.strImportCSV); } else { $('#import_notification').text(''); @@ -27,16 +27,16 @@ function changePluginOpts () { * in the plugin dropdown list according to the format of the selected file */ function matchFile (fname) { - var fname_array = fname.toLowerCase().split('.'); - var len = fname_array.length; + var fnameArray = fname.toLowerCase().split('.'); + var len = fnameArray.length; if (len !== 0) { - var extension = fname_array[len - 1]; + var extension = fnameArray[len - 1]; if (extension === 'gz' || extension === 'bz2' || extension === 'zip') { len--; } // Only toggle if the format of the file can be imported - if ($('select[name=\'format\'] option').filterByValue(fname_array[len - 1]).length === 1) { - $('select[name=\'format\'] option').filterByValue(fname_array[len - 1]).prop('selected', true); + if ($('select[name=\'format\'] option').filterByValue(fnameArray[len - 1]).length === 1) { + $('select[name=\'format\'] option').filterByValue(fnameArray[len - 1]).prop('selected', true); changePluginOpts(); } }