diff options
| author | 2023-05-01 14:25:14 +0100 | |
|---|---|---|
| committer | 2023-05-06 13:20:46 +0100 | |
| commit | e5cce5558c4dd3da38f9106d9b4addb874ea0c4b (patch) | |
| tree | f2f4bd6c78cb89ccc4490653029251d6f248674a /bot/exts | |
| parent | update Roles (diff) | |
update Tokens & Wolfram
Diffstat (limited to 'bot/exts')
| -rw-r--r-- | bot/exts/holidays/easter/earth_photos.py | 6 | ||||
| -rw-r--r-- | bot/exts/utilities/wolfram.py | 4 | 
2 files changed, 5 insertions, 5 deletions
| diff --git a/bot/exts/holidays/easter/earth_photos.py b/bot/exts/holidays/easter/earth_photos.py index e60e2626..5008b24d 100644 --- a/bot/exts/holidays/easter/earth_photos.py +++ b/bot/exts/holidays/easter/earth_photos.py @@ -23,7 +23,7 @@ class EarthPhotos(commands.Cog):          async with ctx.typing():              async with self.bot.http_session.get(                      API_URL, -                    params={"query": "planet_earth", "client_id": Tokens.unsplash_access_key} +                    params={"query": "planet_earth", "client_id": Tokens.unsplash}              ) as r:                  jsondata = await r.json()                  linksdata = jsondata.get("urls") @@ -37,7 +37,7 @@ class EarthPhotos(commands.Cog):                  rf = "?utm_source=Sir%20Lancebot&utm_medium=referral"              async with self.bot.http_session.get(                  downloadlinksdata.get("download_location"), -                    params={"client_id": Tokens.unsplash_access_key} +                    params={"client_id": Tokens.unsplash}              ) as _:                  pass @@ -59,7 +59,7 @@ class EarthPhotos(commands.Cog):  async def setup(bot: Bot) -> None:      """Load the Earth Photos cog.""" -    if not Tokens.unsplash_access_key: +    if not Tokens.unsplash:          log.warning("No Unsplash access key found. Cog not loading.")          return      await bot.add_cog(EarthPhotos(bot)) diff --git a/bot/exts/utilities/wolfram.py b/bot/exts/utilities/wolfram.py index a2f1228a..7dc4d7c3 100644 --- a/bot/exts/utilities/wolfram.py +++ b/bot/exts/utilities/wolfram.py @@ -10,12 +10,12 @@ from discord.ext import commands  from discord.ext.commands import BucketType, Cog, Context, check, group  from bot.bot import Bot -from bot.constants import Colours, STAFF_ROLES, Wolfram +from bot.constants import Colours, STAFF_ROLES, Tokens, Wolfram  from bot.utils.pagination import ImagePaginator  log = logging.getLogger(__name__) -APPID = Wolfram.key +APPID = Tokens.wolfram  DEFAULT_OUTPUT_FORMAT = "JSON"  QUERY = "http://api.wolframalpha.com/v2/{request}"  WOLF_IMAGE = "https://www.symbols.com/gi.php?type=1&id=2886&i=1" | 
