Dont cache the social media domain checks. i can probably put this in other places but just here for now works
This commit is contained in:
parent
9f9240f207
commit
d90a1f6a8a
@ -3,7 +3,6 @@ from discord.ext import commands
|
|||||||
import core_utils
|
import core_utils
|
||||||
import discord
|
import discord
|
||||||
import os
|
import os
|
||||||
import random
|
|
||||||
import requests
|
import requests
|
||||||
import requests_cache
|
import requests_cache
|
||||||
|
|
||||||
@ -93,8 +92,9 @@ async def convert_heic_to_jpg(ctx):
|
|||||||
|
|
||||||
@bot.listen("on_message")
|
@bot.listen("on_message")
|
||||||
async def fix_social_media_links(ctx):
|
async def fix_social_media_links(ctx):
|
||||||
|
headers = {"Cache-Control": "no-store"}
|
||||||
correct_domains = requests.get(
|
correct_domains = requests.get(
|
||||||
core_utils.json_endpoint + "social_media_domains.json"
|
core_utils.json_endpoint + "social_media_domains.json", headers=headers
|
||||||
).json()
|
).json()
|
||||||
|
|
||||||
if ctx.author.id == bot.user.id:
|
if ctx.author.id == bot.user.id:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user