mirror of
https://github.com/Routstr/routstr-core.git
synced 2026-08-10 11:13:08 +00:00
Fix settings override bug: allow False and 0 from database
Fixes #217 - Database values of False and 0 are now properly respected instead of being ignored. Removed 'and v' check that incorrectly treated these legitimate config values as 'empty'. Now only truly empty values (None, empty string, empty list, empty dict) are ignored in favor of env.
This commit is contained in:
@@ -235,7 +235,7 @@ class SettingsService:
|
||||
|
||||
merged_dict: dict[str, Any] = dict(env_resolved.dict())
|
||||
merged_dict.update(
|
||||
{k: v for k, v in db_json.items() if v not in (None, "", []) and v}
|
||||
{k: v for k, v in db_json.items() if v not in (None, "", [], {})}
|
||||
)
|
||||
|
||||
# Ensure primary_mint is consistent with cashu_mints if not explicitly set
|
||||
|
||||
Reference in New Issue
Block a user