use custom prefixes

development v0.0.44
DustyP 5 years ago
parent 414757188e
commit 552664268b

@ -72,7 +72,11 @@ func main() {
}
func getPrefixes(guildID string) []string {
return []string{"G.", "g."}
guild, err := services.GuildService.Guild(guildID)
if err != nil || len(guild.Prefixes) == 0 {
return []string{"G$", "g$"}
}
return guild.Prefixes
}
func ErrorHandler(ErrorChan chan disgoman.CommandError) {

@ -2,7 +2,6 @@ package guild
import (
"fmt"
"log"
"github.com/dustinpianalto/disgoman"
"github.com/dustinpianalto/geeksbot"
@ -90,7 +89,6 @@ func removePrefixCommandFunc(ctx disgoman.Context, args []string) {
l--
i--
removed = append(removed, a)
log.Println(a)
}
}
}

Loading…
Cancel
Save