Refactoring

This commit is contained in:
nistootsin 2025-03-21 18:57:50 +03:30
parent 1aff920e83
commit c14c82767a

View file

@ -73,7 +73,7 @@ const (
EmptyTelegramUserID = int64(0)
)
const charset = "abcdefghijklmnopqrstuvwxyz0123456789"
type Tgbot struct {
inboundService InboundService
@ -453,6 +453,7 @@ func (t *Tgbot) sendResponse(chatId int64, msg string, onlyMessage, isAdmin bool
func (t *Tgbot) randomLowerAndNum(length int) string {
charset := "abcdefghijklmnopqrstuvwxyz0123456789"
bytes := make([]byte, length)
for i := range bytes {
randomIndex, _ := rand.Int(rand.Reader, big.NewInt(int64(len(charset))))