hdkv
/
i2_bot
Archived
1
Fork 0
This repository has been archived on 2022-11-04. You can view files and clone it, but cannot push or open issues/pull-requests.
i2_bot/lib/users/users.go

35 lines
1.4 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

// i2_bot Instinct PokememBro Bot
// Copyright (c) 2017 Vladimir "fat0troll" Hodakov
package users
import (
"github.com/go-telegram-bot-api/telegram-bot-api"
)
// Internal functions for Users package
// profileAddSuccessMessage shows profile addition success message
func (u *Users) profileAddSuccessMessage(update *tgbotapi.Update) {
message := "*Профиль успешно обновлен.*\n\n"
message += "Функциональность бота держится на актуальности профилей. Обновляйся почаще, и да пребудет с тобой Рандом!\n"
message += "Сохраненный профиль ты можешь просмотреть командой /me.\n\n"
message += "/best посмотреть лучших покемемов для поимки"
msg := tgbotapi.NewMessage(update.Message.Chat.ID, message)
msg.ParseMode = "Markdown"
c.Bot.Send(msg)
}
// profileAddFailureMessage shows profile addition failure message
func (u *Users) profileAddFailureMessage(update *tgbotapi.Update) {
message := "*Неудачно получилось :(*\n\n"
message += "Случилась жуткая ошибка, и мы не смогли записать профиль в базу. Напиши @fat0troll, он разберется."
msg := tgbotapi.NewMessage(update.Message.Chat.ID, message)
msg.ParseMode = "Markdown"
c.Bot.Send(msg)
}