From a2912b94b6c89ee6abaddfa04383456dd3e98a01 Mon Sep 17 00:00:00 2001 From: Jeremy Mahieu Date: Fri, 1 May 2020 23:28:54 +0200 Subject: [PATCH] Remove some whitelines --- js/imgur.js | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/js/imgur.js b/js/imgur.js index 877ef0a..f743bc3 100644 --- a/js/imgur.js +++ b/js/imgur.js @@ -104,10 +104,8 @@ weechat.factory('imgur', ['$rootScope', 'settings', function($rootScope, setting }; if( "upload" in xhttp ) { - // Set progress xhttp.upload.onprogress = function (event) { - // Check if we can compute progress if (event.lengthComputable) { // Complete in percent @@ -117,12 +115,9 @@ weechat.factory('imgur', ['$rootScope', 'settings', function($rootScope, setting currentProgressBar.style.width = complete + '%'; } }; - } - // Send request with form data xhttp.send(fd); - }; // Delete an image from imgur with the deletion link @@ -156,22 +151,16 @@ weechat.factory('imgur', ['$rootScope', 'settings', function($rootScope, setting // Handler for response xhttp.onload = function() { - // Check state and response status if(xhttp.status === 200) { - callback(); - } else { showErrorMsg(); } - }; - - + // Send request with form data xhttp.send(null); - }; var showErrorMsg = function() {