fixed incorrect type when changing character costume
This commit is contained in:
@@ -6,6 +6,7 @@ import (
|
||||
"bdgrp_go/routes"
|
||||
"bdgrp_go/utils"
|
||||
"fmt"
|
||||
"strconv"
|
||||
|
||||
"github.com/gofiber/fiber/v2"
|
||||
)
|
||||
@@ -27,7 +28,8 @@ func changeCostume(c *fiber.Ctx) error {
|
||||
|
||||
wearingCostume := user["wearingCostume"].(map[string]any)
|
||||
costume := wearingCostume[characterid].(map[string]any)
|
||||
costume["costumeId"] = costumeid
|
||||
cid, _ := strconv.Atoi(costumeid)
|
||||
costume["costumeId"] = cid
|
||||
db.Save()
|
||||
|
||||
charMap := map[string]any{}
|
||||
|
||||
Reference in New Issue
Block a user