Move time formatter into time.lua