Skip to content

Commit

Permalink
feat: token from env.
Browse files Browse the repository at this point in the history
  • Loading branch information
ap12-code committed Aug 12, 2024
1 parent 05cc8a9 commit da629d3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CommandLab.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import logging.config
from datetime import datetime
from os import listdir
import os

import aiofiles
import discord
Expand Down Expand Up @@ -187,6 +188,8 @@ async def close(self) -> None:

if config.token == "FILE":
config.token = open("..\\CMTK.txt", mode="r").read()
if config.token == "ENV":
config.token = os.getenv("TOKEN")

if __name__ == "__main__":
asyncio.run(CommandLabBot.start(token=config.token))

0 comments on commit da629d3

Please sign in to comment.