mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2025-03-03 20:44:54 +08:00
restore 1.8.0-style naming of scripts
This commit is contained in:
parent
e84703b253
commit
61f6479ea9
@ -8,9 +8,7 @@ loaded_scripts = {}
|
|||||||
|
|
||||||
|
|
||||||
def load_module(path):
|
def load_module(path):
|
||||||
module_name, _ = os.path.splitext(os.path.basename(path))
|
module_spec = importlib.util.spec_from_file_location(os.path.basename(path), path)
|
||||||
full_module_name = "scripts." + module_name
|
|
||||||
module_spec = importlib.util.spec_from_file_location(full_module_name, path)
|
|
||||||
module = importlib.util.module_from_spec(module_spec)
|
module = importlib.util.module_from_spec(module_spec)
|
||||||
module_spec.loader.exec_module(module)
|
module_spec.loader.exec_module(module)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user