generated from HoloTech/twitch-bot-template
Patch for new aio adapter.
This commit is contained in:
@@ -12,11 +12,16 @@ from modules import twitch_setup
|
|||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
||||||
|
class FixedAiohttpAdapter(AiohttpAdapter):
|
||||||
|
def _find_redirect(self, request):
|
||||||
|
return self.redirect_url
|
||||||
|
|
||||||
|
|
||||||
async def main():
|
async def main():
|
||||||
db = Database(conf.data['args'])
|
db = Database(conf.data['args'])
|
||||||
|
|
||||||
async with db.open():
|
async with db.open():
|
||||||
adapter = AiohttpAdapter(
|
adapter = FixedAiohttpAdapter(
|
||||||
host=conf.bot.get('wshost', None),
|
host=conf.bot.get('wshost', None),
|
||||||
port=conf.bot.getint('wsport', None),
|
port=conf.bot.getint('wsport', None),
|
||||||
domain=conf.bot.get('wsdomain', None),
|
domain=conf.bot.get('wsdomain', None),
|
||||||
|
|||||||
Reference in New Issue
Block a user