Store role list in database and convert role mentions into a readable format

This commit is contained in:
Tulir Asokan
2022-07-08 15:31:03 +03:00
parent 668a77e30d
commit 2611cbfa34
8 changed files with 246 additions and 9 deletions

View File

@@ -22,6 +22,7 @@ type Database struct {
Reaction *ReactionQuery
Emoji *EmojiQuery
Guild *GuildQuery
Role *RoleQuery
}
func New(baseDB *dbutil.Database) *Database {
@@ -59,6 +60,10 @@ func New(baseDB *dbutil.Database) *Database {
db: db,
log: db.Log.Sub("Guild"),
}
db.Role = &RoleQuery{
db: db,
log: db.Log.Sub("Role"),
}
return db
}