mirror of
https://github.com/ergochat/ergo.git
synced 2024-11-22 20:09:41 +01:00
add a config sanity check
This commit is contained in:
parent
d48ca682bd
commit
9177e785c5
@ -927,6 +927,10 @@ func LoadConfig(filename string) (config *Config, err error) {
|
|||||||
config.Accounts.Multiclient.AllowedByDefault = true
|
config.Accounts.Multiclient.AllowedByDefault = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if config.Accounts.NickReservation.ForceNickEqualsAccount && !config.Accounts.Multiclient.Enabled {
|
||||||
|
return nil, errors.New("force-nick-equals-account requires enabling multiclient as well")
|
||||||
|
}
|
||||||
|
|
||||||
// handle guest format, including the legacy key rename-prefix
|
// handle guest format, including the legacy key rename-prefix
|
||||||
if config.Accounts.NickReservation.GuestFormat == "" {
|
if config.Accounts.NickReservation.GuestFormat == "" {
|
||||||
renamePrefix := config.Accounts.NickReservation.RenamePrefix
|
renamePrefix := config.Accounts.NickReservation.RenamePrefix
|
||||||
|
Loading…
Reference in New Issue
Block a user