move feeds to ptb

This commit is contained in:
2021-03-20 16:21:13 +03:00
parent b35d2ca251
commit e72cb9a453
12 changed files with 38 additions and 52 deletions
+2 -3
View File
@@ -1,8 +1,7 @@
import re
from datetime import datetime
import feedparser
from telebot import TeleBot
from telegram import Bot
from telegram.constants import MAX_CAPTION_LENGTH
from feeds.models import FeedModuleConfig
@@ -16,7 +15,7 @@ CAPTION_NEWLINE_RE = re.compile(r'(\w*<p>|</p>\w*){1,2}')
class NerfNowFeedModuleConfig(FeedModuleConfig):
MODULE_NAME = 'NerfNow.com'
def execute(self, bot: TeleBot, chat_id, last_id):
def execute(self, bot: Bot, chat_id, last_id):
if last_id is None:
last_id = ''