From 221188b44b6482bf89aed589972f6adfa01c80e5 Mon Sep 17 00:00:00 2001 From: giongto35 Date: Tue, 23 Apr 2019 00:20:11 +0800 Subject: [PATCH] Change roomID format --- main.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/main.go b/main.go index 87b2ba4e..4d594e67 100644 --- a/main.go +++ b/main.go @@ -9,6 +9,7 @@ import ( "math/rand" "net/http" _ "net/http/pprof" + "strconv" "strings" "sync" "time" @@ -319,8 +320,8 @@ func ws(w http.ResponseWriter, r *http.Request) { // generateRoomID generate a unique room ID containing 16 digits func generateRoomID() string { - //roomID := strconv.FormatInt(rand.Int63(), 16) - roomID := uuid.Must(uuid.NewV4()).String() + roomID := strconv.FormatInt(rand.Int63(), 16) + //roomID := uuid.Must(uuid.NewV4()).String() return roomID }