Fix crash when trying to mod nobody

Fixes issue #12
This commit is contained in:
Zorchenhimer 2019-03-10 21:35:24 -04:00
parent 5b75615b90
commit 02400b667c

View File

@ -140,6 +140,9 @@ func init() {
admin: map[string]CommandFunction{
"mod": func(cl *Client, args []string) string {
if len(args) == 0 {
return "Missing user to mod."
}
if err := cl.belongsTo.Mod(args[0]); err != nil {
return err.Error()
}