From: Alexander Moisseev Date: Sat, 15 Sep 2018 16:32:20 +0000 (+0300) Subject: [Minor] Enforce return after callback X-Git-Tag: 1.8.0~95^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dff3186aa7c0020d0fb3fad7950dbcf4bee6a36f;p=thirdparty%2Frspamd.git [Minor] Enforce return after callback --- diff --git a/.eslintrc.json b/.eslintrc.json index bf4c767c92..b04b72b4bf 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -53,7 +53,6 @@ // Temporarily disabled rules "array-callback-return": "off", "array-element-newline": "off", - "callback-return": "off", "consistent-return": "off", "consistent-this": "off", "func-style": "off", diff --git a/interface/js/app/history.js b/interface/js/app/history.js index fa80a10cdc..990f60a093 100644 --- a/interface/js/app/history.js +++ b/interface/js/app/history.js @@ -608,7 +608,7 @@ define(["jquery", "footable", "humanize"], var i = (typeof iteration === "undefined") ? 10 : iteration; var num_rows = $("#historyTable > tbody > tr").length; if (num_rows === rows_per_page) { - callback(); + return callback(); } else if (--i) { setTimeout(function () { waitForRowsDisplayed(callback, i);