mailbox activation, closes #52
This commit is contained in:
@@ -3,6 +3,8 @@ package bot
|
||||
import (
|
||||
"strings"
|
||||
|
||||
"maunium.net/go/mautrix/id"
|
||||
|
||||
"gitlab.com/etke.cc/postmoogle/utils"
|
||||
)
|
||||
|
||||
@@ -11,6 +13,7 @@ const acBotSettingsKey = "cc.etke.postmoogle.config"
|
||||
|
||||
// bot options keys
|
||||
const (
|
||||
botOptionAdminRoom = "adminroom"
|
||||
botOptionUsers = "users"
|
||||
botOptionCatchAll = "catch-all"
|
||||
botOptionDKIMSignature = "dkim.pub"
|
||||
@@ -52,6 +55,11 @@ func (s botSettings) CatchAll() string {
|
||||
return s.Get(botOptionCatchAll)
|
||||
}
|
||||
|
||||
// AdminRoom option
|
||||
func (s botSettings) AdminRoom() id.RoomID {
|
||||
return id.RoomID(s.Get(botOptionAdminRoom))
|
||||
}
|
||||
|
||||
// BanlistEnabled option
|
||||
func (s botSettings) BanlistEnabled() bool {
|
||||
return utils.Bool(s.Get(botOptionBanlistEnabled))
|
||||
|
||||
Reference in New Issue
Block a user