libs/time.lua

Sat, 14 Nov 2020 15:24:01 +0100

author
Kim Alvefur <zash@zash.se>
date
Sat, 14 Nov 2020 15:24:01 +0100
changeset 440
14071b3a46df
child 471
788d4d91ef6b
permissions
-rw-r--r--

util.time: Add pure Lua version of Prosody C module

-- Import gettime() from LuaSocket, as a way to access high-resolution time
-- in a platform-independent way

local socket_gettime = require "socket".gettime;

return {
	now = socket_gettime;
}

mercurial