调整ws错误消息显示,整理翻译文本
This commit is contained in:
@@ -53,11 +53,11 @@ end
|
||||
|
||||
--wsEvent
|
||||
function NET.wsCloseMessage(message)
|
||||
if message:sub(1,1)=="{"then
|
||||
local mes=JSON.decode(message)
|
||||
LOG.print(text.wsClose..mes.type,"warn")
|
||||
local mes=JSON.decode(message)
|
||||
if mes then
|
||||
LOG.print(("%s [%s] %s"):format(text.wsClose,mes.type or"unknown type",mes.reason or""),"warn")
|
||||
else
|
||||
LOG.print(text.wsClose..type,"warn")
|
||||
LOG.print(text.wsClose.."","warn")
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user