WIP.
Long-polling errors seem to be due to tthe dev server crashes earlier.
This commit is contained in:
parent
58a01bff56
commit
216ec90646
2 changed files with 6 additions and 2 deletions
|
|
@ -8,6 +8,7 @@ import (
|
|||
"os"
|
||||
"os/signal"
|
||||
"slices"
|
||||
"time"
|
||||
|
||||
"code.destrealm.net/zancarius/justusbot/internal/settings"
|
||||
"github.com/mymmrac/telego"
|
||||
|
|
@ -227,7 +228,9 @@ func (b *bot) SetPolling(ctx context.Context, conf *settings.Settings) (err erro
|
|||
}
|
||||
}
|
||||
|
||||
updates, err := b.tgbot.UpdatesViaLongPolling(ctx, nil)
|
||||
updates, err := b.tgbot.UpdatesViaLongPolling(ctx, &telego.GetUpdatesParams{
|
||||
Timeout: 300,
|
||||
}, telego.WithLongPollingUpdateInterval(time.Second*30))
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue