Auto setting conf.debug=True if env var BOT_DEV is set
This commit is contained in:
parent
4c02227c4b
commit
f341503101
|
@ -39,6 +39,9 @@ class Bot(irc3.IrcBot):
|
||||||
with open(cfg_file, 'r') as fp:
|
with open(cfg_file, 'r') as fp:
|
||||||
conf = json.load(fp)
|
conf = json.load(fp)
|
||||||
|
|
||||||
|
if cls.DEV:
|
||||||
|
conf['debug'] = True
|
||||||
|
|
||||||
bot = cls.from_config(conf)
|
bot = cls.from_config(conf)
|
||||||
bot.cfg_file = cfg_file
|
bot.cfg_file = cfg_file
|
||||||
bot.env_file = env_file
|
bot.env_file = env_file
|
||||||
|
|
Loading…
Reference in New Issue
Block a user