Fix Avvio KoD

This commit is contained in:
Alhaziel01
2021-08-03 22:27:14 +02:00
parent 25d4522e1c
commit bf8d9d68b1

View File

@@ -159,10 +159,10 @@ def run(item=None):
channel = None
if os.path.exists(channel_file):
try:
channel = __import__('%s.%s' % (CHANNELS, item.channel), None, None, ['%s.%s' % (CHANNELS, item.channel)])
except ImportError:
exec("import " + CHANNELS + "." + item.channel + " as channel")
# try:
channel = __import__('%s.%s' % (CHANNELS, item.channel), None, None, ['%s.%s' % (CHANNELS, item.channel)])
# except ImportError:
# exec("import " + CHANNELS + "." + item.channel + " as channel")
logger.info("Running channel %s | %s" % (channel.__name__, channel.__file__))