change user type from int to uuid string

This commit is contained in:
2025-03-27 20:33:48 -04:00
parent 732fbacc61
commit 9d7ad260f2
5 changed files with 35 additions and 29 deletions

View File

@@ -1,7 +1,15 @@
package api
import (
"github.com/google/uuid"
)
func newUserID() string {
return "user_" + uuid.New().String()
}
type User struct {
ID int64 `json:"id"`
ID string `json:"id"`
Name string `json:"name"`
}