mirror of
https://github.com/Mayuri-Chan/pyrofork.git
synced 2026-01-06 15:14:52 +00:00
Sanitize (a bit) plugins directory
This commit is contained in:
parent
4e516d097f
commit
6c05f9ff42
1 changed files with 3 additions and 1 deletions
|
|
@ -239,8 +239,10 @@ class Client(Methods, BaseClient):
|
||||||
else:
|
else:
|
||||||
log.warning(e)
|
log.warning(e)
|
||||||
else:
|
else:
|
||||||
|
plugins_dir = self.plugins_dir.lstrip("./").replace("/", ".")
|
||||||
|
|
||||||
for i in dirs:
|
for i in dirs:
|
||||||
module = import_module("{}.{}".format(self.plugins_dir, i.split(".")[0]))
|
module = import_module("{}.{}".format(plugins_dir, i.split(".")[0]))
|
||||||
|
|
||||||
for j in dir(module):
|
for j in dir(module):
|
||||||
# noinspection PyBroadException
|
# noinspection PyBroadException
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue