PamGram/utils/patch/telegram.py

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

15 lines
433 B
Python
Raw Normal View History

2024-06-18 17:33:28 +00:00
import telegram
from utils.patch.methods import patch, patchable
# https://github.com/python-telegram-bot/python-telegram-bot/issues/4295
@patch(telegram.Bot)
class Bot:
@patchable
def _effective_inline_results(self, results, next_offset=None, current_offset=None):
if current_offset == "[]":
current_offset = 50
return self.old__effective_inline_results(results, next_offset, current_offset)