From: Vsevolod Stakhov Date: Fri, 29 Apr 2016 12:23:40 +0000 (+0100) Subject: [Minor] Fix percents output in R_PARTS_DIFFER X-Git-Tag: 1.2.6~3 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=fe1c169a023484fb248a8f2d4d8e4686593efbbd;p=rspamd.git [Minor] Fix percents output in R_PARTS_DIFFER --- diff --git a/rules/misc.lua b/rules/misc.lua index 68a64f7be..11f482562 100644 --- a/rules/misc.lua +++ b/rules/misc.lua @@ -50,7 +50,8 @@ rspamd_config.R_PARTS_DIFFER = function(task) -- We are not so confident about difference score = (nd - 0.5) end - task:insert_result('R_PARTS_DIFFER', score, tostring(100.0 * nd) .. '%') + task:insert_result('R_PARTS_DIFFER', score, + string.format('%.1f%%', tostring(100.0 * nd))) end end end