mirror of
https://github.com/QuantumNous/new-api.git
synced 2026-03-30 09:35:21 +00:00
22 lines
523 B
Go
22 lines
523 B
Go
package system_setting
|
|
|
|
import "github.com/QuantumNous/new-api/setting/config"
|
|
|
|
type DiscordSettings struct {
|
|
Enabled bool `json:"enabled"`
|
|
ClientId string `json:"client_id"`
|
|
ClientSecret string `json:"client_secret"`
|
|
}
|
|
|
|
// 默认配置
|
|
var defaultDiscordSettings = DiscordSettings{}
|
|
|
|
func init() {
|
|
// 注册到全局配置管理器
|
|
config.GlobalConfig.Register("discord", &defaultDiscordSettings)
|
|
}
|
|
|
|
func GetDiscordSettings() *DiscordSettings {
|
|
return &defaultDiscordSettings
|
|
}
|