mirror of
https://github.com/Mayuri-Chan/pyrofork.git
synced 2026-01-01 05:04:51 +00:00
Fix the configuration load process breaking in case of no plugins
This commit is contained in:
parent
5e97cb3420
commit
a8a6f53e2d
1 changed files with 8 additions and 7 deletions
|
|
@ -1087,14 +1087,15 @@ class Client(Methods, BaseClient):
|
|||
"exclude": section.get("exclude") or None
|
||||
}
|
||||
except KeyError:
|
||||
pass
|
||||
self.plugins = {}
|
||||
|
||||
for option in ["include", "exclude"]:
|
||||
if self.plugins[option] is not None:
|
||||
self.plugins[option] = [
|
||||
(i.split()[0], i.split()[1:] or None)
|
||||
for i in self.plugins[option].strip().split("\n")
|
||||
]
|
||||
if self.plugins:
|
||||
for option in ["include", "exclude"]:
|
||||
if self.plugins[option] is not None:
|
||||
self.plugins[option] = [
|
||||
(i.split()[0], i.split()[1:] or None)
|
||||
for i in self.plugins[option].strip().split("\n")
|
||||
]
|
||||
|
||||
def load_session(self):
|
||||
try:
|
||||
|
|
|
|||
Loading…
Reference in a new issue