mirror of
https://github.com/Mayuri-Chan/pyrofork.git
synced 2026-01-03 05:54:51 +00:00
Fix "ModuleNotFoundError is not defined" error for Python <3.6
This commit is contained in:
parent
2a9c34481f
commit
64775f5209
1 changed files with 2 additions and 2 deletions
|
|
@ -1179,7 +1179,7 @@ class Client(Methods, BaseClient):
|
||||||
|
|
||||||
try:
|
try:
|
||||||
module = import_module(module_path)
|
module = import_module(module_path)
|
||||||
except ModuleNotFoundError:
|
except ImportError:
|
||||||
log.warning('[LOAD] Ignoring non-existent module "{}"'.format(module_path))
|
log.warning('[LOAD] Ignoring non-existent module "{}"'.format(module_path))
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
|
@ -1215,7 +1215,7 @@ class Client(Methods, BaseClient):
|
||||||
|
|
||||||
try:
|
try:
|
||||||
module = import_module(module_path)
|
module = import_module(module_path)
|
||||||
except ModuleNotFoundError:
|
except ImportError:
|
||||||
log.warning('[UNLOAD] Ignoring non-existent module "{}"'.format(module_path))
|
log.warning('[UNLOAD] Ignoring non-existent module "{}"'.format(module_path))
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue