👽 Change avatar and banner id to string

This commit is contained in:
2024-08-18 22:08:58 +08:00
parent dd3586b241
commit 0285b82ca2
3 changed files with 11 additions and 13 deletions

View File

@ -15,7 +15,7 @@ func setAvatar(c *fiber.Ctx) error {
user := c.Locals("user").(models.Account)
var data struct {
AttachmentID uint `json:"attachment" validate:"required"`
AttachmentID string `json:"attachment" validate:"required"`
}
if err := exts.BindAndValidate(c, &data); err != nil {
@ -40,7 +40,7 @@ func setBanner(c *fiber.Ctx) error {
user := c.Locals("user").(models.Account)
var data struct {
AttachmentID uint `json:"attachment" validate:"required"`
AttachmentID string `json:"attachment" validate:"required"`
}
if err := exts.BindAndValidate(c, &data); err != nil {