summaryrefslogtreecommitdiffstats
path: root/api/command_shrug.go
diff options
context:
space:
mode:
author=Corey Hulen <corey@hulen.com>2016-02-01 18:52:43 -0800
committer=Corey Hulen <corey@hulen.com>2016-02-01 18:52:43 -0800
commit27586a320add265f3e032d2cb21b27e93b51a2b0 (patch)
tree5158d1ffeb0f3a922b0036f560b3c99862373275 /api/command_shrug.go
parentb4ec6900510077253290e361d1a706e5368a45de (diff)
downloadchat-27586a320add265f3e032d2cb21b27e93b51a2b0.tar.gz
chat-27586a320add265f3e032d2cb21b27e93b51a2b0.tar.bz2
chat-27586a320add265f3e032d2cb21b27e93b51a2b0.zip
Adding loc to new command backend
Diffstat (limited to 'api/command_shrug.go')
-rw-r--r--api/command_shrug.go18
1 files changed, 13 insertions, 5 deletions
diff --git a/api/command_shrug.go b/api/command_shrug.go
index c49bd46ae..8fb5bc200 100644
--- a/api/command_shrug.go
+++ b/api/command_shrug.go
@@ -10,17 +10,25 @@ import (
type ShrugProvider struct {
}
+const (
+ CMD_SHRUG = "shrug"
+)
+
func init() {
RegisterCommandProvider(&ShrugProvider{})
}
-func (me *ShrugProvider) GetCommand() *model.Command {
+func (me *ShrugProvider) GetTrigger() string {
+ return CMD_SHRUG
+}
+
+func (me *ShrugProvider) GetCommand(c *Context) *model.Command {
return &model.Command{
- Trigger: "shrug",
+ Trigger: CMD_SHRUG,
AutoComplete: true,
- AutoCompleteDesc: `Adds ¯\_(ツ)_/¯ to your message`,
- AutoCompleteHint: "[message]",
- DisplayName: "shrug",
+ AutoCompleteDesc: c.T("api.command_shrug.desc"),
+ AutoCompleteHint: c.T("api.command_shrug.hint"),
+ DisplayName: c.T("api.command_shrug.name"),
}
}