mirror of
https://github.com/easydiffusion/easydiffusion.git
synced 2025-04-24 11:28:19 +02:00
Fix unnecessary warning for config.json
This commit is contained in:
parent
622322c878
commit
a6b4d59d94
@ -148,6 +148,9 @@ def getAppConfig():
|
|||||||
try:
|
try:
|
||||||
config_json_path = os.path.join(CONFIG_DIR, 'config.json')
|
config_json_path = os.path.join(CONFIG_DIR, 'config.json')
|
||||||
|
|
||||||
|
if not os.path.exists(config_json_path):
|
||||||
|
return HTTPException(status_code=500, detail="No config file")
|
||||||
|
|
||||||
with open(config_json_path, 'r') as f:
|
with open(config_json_path, 'r') as f:
|
||||||
config_json_str = f.read()
|
config_json_str = f.read()
|
||||||
config = json.loads(config_json_str)
|
config = json.loads(config_json_str)
|
||||||
|
Loading…
Reference in New Issue
Block a user