2024-05-09 20:48:59 +03:00
|
|
|
package wizard
|
|
|
|
|
|
|
|
import (
|
|
|
|
"gitea.neur0tx.site/Neur0toxine/vegapokerbot/internal/handler/iface"
|
|
|
|
"github.com/mymmrac/telego"
|
|
|
|
tu "github.com/mymmrac/telego/telegoutil"
|
|
|
|
)
|
|
|
|
|
|
|
|
type HelpCommand struct {
|
2024-05-09 23:26:21 +03:00
|
|
|
iface.Base
|
2024-05-09 20:48:59 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
func NewHelpCommand(app iface.App, userID, chatID int64) *HelpCommand {
|
2024-05-09 23:26:21 +03:00
|
|
|
return &HelpCommand{iface.NewBase(app, userID, chatID)}
|
2024-05-09 20:48:59 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
func (h *HelpCommand) Handle(wh telego.Update) error {
|
|
|
|
_, err := h.App.TG().SendMessage(&telego.SendMessageParams{
|
|
|
|
ChatID: tu.ID(wh.Message.Chat.ID),
|
2024-05-09 23:26:21 +03:00
|
|
|
Text: h.Localizer(wh.Message.From.LanguageCode).Message("help_output"),
|
2024-05-09 20:48:59 +03:00
|
|
|
ParseMode: telego.ModeMarkdown,
|
|
|
|
})
|
|
|
|
return err
|
|
|
|
}
|