Knut Ahlers
f1d35ce7c0
and with that support all databases the bot does support Signed-off-by: Knut Ahlers <knut@ahlers.me>
26 lines
561 B
Go
26 lines
561 B
Go
package database
|
|
|
|
type (
|
|
StreakMeta struct {
|
|
Name string `gorm:"primaryKey"`
|
|
Value string
|
|
}
|
|
|
|
StreakUser struct {
|
|
TwitchID uint64 `gorm:"primaryKey"`
|
|
Username string
|
|
StreamsCount uint64
|
|
CurrentStreak uint64
|
|
MaxStreak uint64
|
|
StreakStatus Status
|
|
}
|
|
|
|
Status string
|
|
)
|
|
|
|
const (
|
|
StatusBroken Status = "broken" // Streak is broken and must be started anew
|
|
StatusPending Status = "pending" // Streak is pending to be broken and can be continued
|
|
StatusActive Status = "active" // Streak is active (renewed in current stream)
|
|
)
|