aboutsummaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
Diffstat (limited to 'util')
-rw-r--r--util/session.lua8
1 files changed, 8 insertions, 0 deletions
diff --git a/util/session.lua b/util/session.lua
index 6993842c..7703c265 100644
--- a/util/session.lua
+++ b/util/session.lua
@@ -1,3 +1,4 @@
+local logger = require "util.logger";
local function new_session(typ)
local session = {
@@ -12,7 +13,14 @@ local function set_id(session)
return session;
end
+local function set_logger(session)
+ local log = logger.init(id);
+ session.log = log;
+ return session;
+end
+
return {
new = new_session;
set_id = set_id;
+ set_logger = set_logger;
}