Files
2026-08-24 08:11:59 -07:00

13 lines
397 B
Python

from collections.abc import Mapping
from typing import Any
def merge_settings(base: Mapping[str, Any], overlay: Mapping[str, Any]) -> dict[str, Any]:
result = dict(base)
for key, value in overlay.items():
if isinstance(value, Mapping) and isinstance(result.get(key), Mapping):
result[key].update(value)
else:
result[key] = value
return result