From 8ad77ea555577186e0c428167cb48191fa5b9bb6 Mon Sep 17 00:00:00 2001 From: kanako <4190346+mkanako@users.noreply.github.com> Date: Fri, 25 Jun 2021 16:55:41 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=94=A8=E6=88=B7=E7=A6=BB?= =?UTF-8?q?=E7=BA=BF=E6=97=B6=EF=BC=8C=E8=B0=83=E7=94=A8=E8=BD=AC=E6=8E=A5?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E6=8A=A5=E9=94=99=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ws/ws.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ws/ws.go b/ws/ws.go index 3deddb1..1c16de6 100644 --- a/ws/ws.go +++ b/ws/ws.go @@ -139,6 +139,8 @@ func WsServerBackend() { } } func UpdateVisitorUser(visitorId string, toId string) { - guest, _ := ClientList[visitorId] - guest.To_id = toId + guest, ok := ClientList[visitorId] + if ok { + guest.To_id = toId + } }