Update linkedGet.lua

This commit is contained in:
erius0 2021-01-08 17:49:01 +03:00 committed by GitHub
parent cf92e71467
commit b6c7d23a13
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -48,13 +48,12 @@ end
while true do
local _, _, from, _, _, message = event.pull("modem_message")
local answer = handleMessage(tostring(message))
local result = handleMessage(tostring(message))
local time = getTime()
local user = getUser(tostring(from))
local log = "["..time.."] "..user..": "..message.."\n".."["..time.."] "..answer
local log = "["..time.."] "..user..": "..message.."\n".."["..time.."] "..result
print(log)
local f = io.open("logs.txt", "a")
f:write(log.."\n")
f:close()
tunnel.send(from, answer)
end