mirror of
https://github.com/myned/modufur.git
synced 2024-12-25 14:47:29 +00:00
Merge branch 'dev'
This commit is contained in:
commit
e2d24ec312
1 changed files with 1 additions and 1 deletions
|
@ -85,7 +85,7 @@ asession = aiohttp.ClientSession()
|
||||||
|
|
||||||
|
|
||||||
async def fetch(url, *, json=False, response=False, text=False):
|
async def fetch(url, *, json=False, response=False, text=False):
|
||||||
if 'e621' in url or 'e926' in url:
|
if '.json' in url and ('e621' in url or 'e926' in url):
|
||||||
url += f'&login=BotMyned&api_key={config["e621_api"]}'
|
url += f'&login=BotMyned&api_key={config["e621_api"]}'
|
||||||
async with asession.get(url, headers={
|
async with asession.get(url, headers={
|
||||||
'User-Agent': 'Myned/Modufur (https://github.com/Myned/Modufur)'}, ssl=False) as r:
|
'User-Agent': 'Myned/Modufur (https://github.com/Myned/Modufur)'}, ssl=False) as r:
|
||||||
|
|
Loading…
Reference in a new issue