Software /
code /
prosody
Diff
util/human/units.lua @ 12802:4a8740e01813
Merge 0.12->trunk
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 12 Dec 2022 07:10:54 +0100 |
parent | 12589:39ae08180c81 |
line wrap: on
line diff
--- a/util/human/units.lua Mon Dec 12 20:40:23 2022 +0100 +++ b/util/human/units.lua Mon Dec 12 07:10:54 2022 +0100 @@ -4,15 +4,7 @@ local math_log = math.log; local math_max = math.max; local math_min = math.min; -local unpack = table.unpack or unpack; --luacheck: ignore 113 - -if math_log(10, 10) ~= 1 then - -- Lua 5.1 COMPAT - local log10 = math.log10; - function math_log(n, base) - return log10(n) / log10(base); - end -end +local unpack = table.unpack; local large = { "k", 1000,