diff options
author | Kim Alvefur <zash@zash.se> | 2016-02-22 17:32:11 +0100 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2016-02-22 17:32:11 +0100 |
commit | 5a4948a7447c459b604465d412759c44afc4362e (patch) | |
tree | 9c0683737e2311956a33db56c3e8c4b5e5505974 | |
parent | 58a6a4b140a317a9e77c803dfda08c5e4770e3fa (diff) | |
download | prosody-5a4948a7447c459b604465d412759c44afc4362e.tar.gz prosody-5a4948a7447c459b604465d412759c44afc4362e.zip |
util.session: Fix luacheck warnings
-rw-r--r-- | util/session.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/util/session.lua b/util/session.lua index fda7fccd..b2a726ce 100644 --- a/util/session.lua +++ b/util/session.lua @@ -9,13 +9,13 @@ local function new_session(typ) end local function set_id(session) - local id = typ .. tostring(session):match("%x+$"):lower(); + local id = session.type .. tostring(session):match("%x+$"):lower(); session.id = id; return session; end local function set_logger(session) - local log = logger.init(id); + local log = logger.init(session.id); session.log = log; return session; end @@ -30,7 +30,7 @@ local function set_send(session) local conn = session.conn; if not conn then function session.send(data) - log("debug", "Discarding data sent to unconnected session: %s", tostring(data)); + session.log("debug", "Discarding data sent to unconnected session: %s", tostring(data)); return false; end return session; |