env vars testing

This commit is contained in:
2026-01-04 05:36:35 -06:00
parent 34f34e3def
commit 4ddcd2b374
6 changed files with 24 additions and 16 deletions

View File

@@ -1,5 +1,5 @@
import os
import re
import config
import discord
import aiohttp
from garfpy import logger
@@ -7,7 +7,7 @@ from garfpy import logger
class WeatherAPI:
def __init__(self, api_key=None):
self.api_key = api_key or config.WEATHER_TOKEN
self.api_key = api_key or os.getenv("WEATHER_TOKEN")
self.base_url = "https://api.openweathermap.org/data/2.5/weather"
def parse_location(self, location):