|
@ -1,7 +1,7 @@ |
|
|
from discord.ext import tasks |
|
|
from discord.ext import tasks |
|
|
import discord |
|
|
import discord |
|
|
from ..bot import DiscordClient |
|
|
from ..bot import DiscordClient |
|
|
import re |
|
|
import re, os |
|
|
|
|
|
|
|
|
class Extension: |
|
|
class Extension: |
|
|
allow_domains = ["steamcommunity.com","s.team","tenor.com","tf2.pblr-nyk.pro", "pblr-nyk.pro", "youtu.be", "youtube.com"] |
|
|
allow_domains = ["steamcommunity.com","s.team","tenor.com","tf2.pblr-nyk.pro", "pblr-nyk.pro", "youtu.be", "youtube.com"] |
|
@ -9,6 +9,7 @@ class Extension: |
|
|
allow_roles = [744928190895489074, 976924951447736453] |
|
|
allow_roles = [744928190895489074, 976924951447736453] |
|
|
core = None |
|
|
core = None |
|
|
def __init__(self, core: DiscordClient): |
|
|
def __init__(self, core: DiscordClient): |
|
|
|
|
|
if not os.getenv("URLCHECKER_ENABLED", None): return None |
|
|
self.core = core |
|
|
self.core = core |
|
|
@core.event |
|
|
@core.event |
|
|
async def on_message(message: discord.Message): |
|
|
async def on_message(message: discord.Message): |
|
|