free-claude-code/providers/common/utils.py
2026-02-27 19:50:21 -08:00

9 lines
272 B
Python

"""Shared utility helpers for provider request builders."""
from typing import Any
def set_if_not_none(body: dict[str, Any], key: str, value: Any) -> None:
"""Set body[key] = value only when value is not None."""
if value is not None:
body[key] = value