mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
prevent crash when no default model defined
This commit is contained in:
parent
2217998010
commit
c79678a643
@ -608,7 +608,7 @@ def new_config_file_contents(successfully_downloaded: dict, config_file: Path) -
|
||||
# if no default model was chosen, then we select the first
|
||||
# one in the list
|
||||
if not default_selected:
|
||||
conf[successfully_downloaded.keys()[0]]["default"] = True
|
||||
conf[list(successfully_downloaded.keys())[0]]["default"] = True
|
||||
|
||||
return OmegaConf.to_yaml(conf)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user