diff options
| author | Anhgelus Morhtuuzh <william@herges.fr> | 2026-03-07 13:20:56 +0100 |
|---|---|---|
| committer | Anhgelus Morhtuuzh <william@herges.fr> | 2026-03-07 13:29:46 +0100 |
| commit | 89b23632f5ceeebd82132210c1407dc9514a547b (patch) | |
| tree | 647782dc5f1b1148893c10bc8b3e712b6ea8362b /user/member.go | |
| parent | 9da4d0379b10da8b33563dcd280aa2a9586aa3fb (diff) | |
feat(gokord): replace snowflake by uintrefactor/leave-old-gokord
Diffstat (limited to 'user/member.go')
| -rw-r--r-- | user/member.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/user/member.go b/user/member.go index e3a1d30..db39911 100644 --- a/user/member.go +++ b/user/member.go @@ -9,16 +9,16 @@ import ( type Copaing struct { ID uint `gorm:"primarykey"` - DiscordID string `gorm:"not null"` + DiscordID uint64 `gorm:"not null"` CopaingXPs []CopaingXP `gorm:"constraint:OnDelete:SET NULL;"` - GuildID string `gorm:"not null"` + GuildID uint64 `gorm:"not null"` } type CopaingXP struct { ID uint `gorm:"primarykey"` XP uint `gorm:"default:0"` CopaingID uint - GuildID string `gorm:"not null;"` + GuildID uint64 `gorm:"not null;"` CreatedAt time.Time } @@ -27,7 +27,7 @@ type CopaingAccess interface { GetXP() uint } -func GetCopaing(ctx context.Context, discordID string, guildID string) *CopaingCached { +func GetCopaing(ctx context.Context, discordID, guildID uint64) *CopaingCached { state := GetState(ctx) cc, err := state.Copaing(guildID, discordID) if err != nil { |
