2,875
edits
No edit summary |
(Remove unused functions) |
||
Line 2: | Line 2: | ||
local Number = require('Module:Number') | local Number = require('Module:Number') | ||
local StringBuilder = require('Module:StringBuilder') | |||
function p._secondsToHMS(totalSeconds) | |||
function p. | |||
local days = math.floor(totalSeconds / (24 * 60 * 60)) | local days = math.floor(totalSeconds / (24 * 60 * 60)) | ||
if days >= 1 then | if days >= 1 then | ||
Line 13: | Line 13: | ||
end | end | ||
function p._secondsToHuman(totalSeconds) | |||
function p. | |||
ts = Number.secondsToTimeSpan(totalSeconds) | ts = Number.secondsToTimeSpan(totalSeconds) | ||
if ts.totalSeconds < 60 then | if ts.totalSeconds < 60 then | ||
Line 39: | Line 38: | ||
end | end | ||
function | function p.secondsToHuman(frame) | ||
local frame = frame or mw.getCurrentFrame() | |||
local args = frame:getParent().args | |||
return p._secondsToHuman(args[0]) | |||
local | |||
end | end | ||
return p | return p |
edits