Skip to content

Commit

Permalink
cc: fix showing trigger for non-text types (botlabs-gg#1005)
Browse files Browse the repository at this point in the history
  • Loading branch information
jo3-l authored Jul 23, 2021
1 parent ee46e42 commit 7a8d2a2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions customcommands/bot.go
Original file line number Diff line number Diff line change
Expand Up @@ -249,8 +249,8 @@ func FindCommands(ccs []*models.CustomCommand, data *dcmd.Data) (foundCCS []*mod
func StringCommands(ccs []*models.CustomCommand, gMap map[int64]string) string {
out := ""
for _, cc := range ccs {
switch cc.TextTrigger {
case "":
switch {
case cc.TriggerType >= 5:
out += fmt.Sprintf("`#%3d:` %s - Group: `%s`\n", cc.LocalID, CommandTriggerType(cc.TriggerType).String(), gMap[cc.GroupID.Int64])
default:
out += fmt.Sprintf("`#%3d:` `%s`: %s - Group: `%s`\n", cc.LocalID, cc.TextTrigger, CommandTriggerType(cc.TriggerType).String(), gMap[cc.GroupID.Int64])
Expand Down

0 comments on commit 7a8d2a2

Please sign in to comment.