Use new simplified uuid.NewString() syntax

This commit is contained in:
Deluan
2021-02-01 01:22:31 -05:00
parent b47ec02f02
commit 861b406575
10 changed files with 17 additions and 32 deletions
+1 -2
View File
@@ -40,9 +40,8 @@ func (p *players) Register(ctx context.Context, id, client, typ, ip string) (*mo
if err == nil {
log.Debug("Found player by name", "id", plr.ID, "client", client, "username", userName)
} else {
r, _ := uuid.NewRandom()
plr = &model.Player{
ID: r.String(),
ID: uuid.NewString(),
Name: fmt.Sprintf("%s (%s)", client, userName),
UserName: userName,
Client: client,