Zomerfestival commit

This commit is contained in:
2021-07-09 11:11:09 +02:00
parent 28564ca913
commit 522abdff1a
11 changed files with 225 additions and 17 deletions

View File

@@ -1,14 +1,9 @@
#!/usr/bin/env python 3
from jeevesbot import env
# import urllib
import aiohttp
import dice
# This function is necessary for tenor, because they do not allow linking directly to the gif and need resolving.
#def resolve(url):
# return urllib.request.urlopen(url).url
# This function is necessary for tenor, because they do not allow linking directly to the gif and need resolving. ASYNC VERSION
async def resolve(url):
async with aiohttp.ClientSession() as session:
@@ -33,4 +28,5 @@ def checkchannel(channelid):
if channelid in env.GIFCHANNELS:
return True
else:
return False
return False