diff --git a/internal/services/tele/commands/token.go b/internal/services/tele/commands/token.go index e64d6ac..3ef9698 100644 --- a/internal/services/tele/commands/token.go +++ b/internal/services/tele/commands/token.go @@ -1,7 +1,8 @@ package commands import ( - "fmt" + "golang.org/x/text/language" + "golang.org/x/text/message" "gopkg.in/telebot.v3" "me.thuanle/bbot/internal/configs/tele" "me.thuanle/bbot/internal/data" @@ -47,10 +48,12 @@ func OnTokenInfoByToken(context telebot.Context, token string) error { baseTotal := baseAmount * basePrice curTotal := baseAmount * sp - msg := fmt.Sprintf( - "🎉∑ Bắc Kiều Phong's USDT: %.0f\n"+ - "🎊 Bắc Kiều Phong's lợi nhuận: %.0f", - baseTotal, curTotal-baseTotal, + mFmt := message.NewPrinter(language.AmericanEnglish) + + msg := mFmt.Sprintf( + "🎉∑ Bắc Kiều Foy's USDT: %.0f\n"+ + "🎊 Bắc Kiều Foy's lợi nhuận: %.0f", + curTotal, curTotal-baseTotal, ) _ = chat.ReplyMessage(context, msg) }