Update string

This commit is contained in:
Astra 2026-02-14 18:51:47 +01:00
parent 26269d30f9
commit ae83679b2b

View file

@ -77,7 +77,7 @@ func main() {
if update.Message.Chat.ID == b.Config.AdminChatId && update.Message.ReplyToMessage != nil {
// handle admin declineion reason
repliedMsg := update.Message.ReplyToMessage
if strings.Contains(repliedMsg.Text, "(no reason provided, reply to this to send one, prepend with + to also send to user)") {
if strings.Contains(repliedMsg.Text, "(no reason provided, reply to this to set one, prepend with + to also send to user)") {
// now we need to make sure the one that declined it is the one replying
lines := strings.Split(repliedMsg.Text, "\n")
userString := ""
@ -241,7 +241,7 @@ func (bot *Bot) handleCallbackQuery(query *api.CallbackQuery) {
edit := api.NewEditMessageText(bot.Config.AdminChatId, user.JoinRequestMessageID,
fmt.Sprintf(AdminDeclinedMsg,
userString, user.From.ID, user.JoinReason, adminUserString, time.Now().Format("2006-01-02 15:04:05"),
"(no reason provided, reply to this to send one, prepend with + to also send to user)"))
"(no reason provided, reply to this to set one, prepend with + to also send to user)"))
edit.ParseMode = api.ModeHTML
bot.API.Send(edit)