def METHOD_NAME(
    self,
    config: dict,
    interfaces: list,
    **kwargs,
) -> None:
    body = {"spec": kwargs}
    spec = body["spec"]
    if config:
        spec["config"] = config
    if interfaces:
        spec["interfaces"] = interfaces
    self.crd_api.patch_namespaced_custom_object(
        group=consts.CRD_API_GROUP,
        version=consts.CRD_API_VERSION,
        plural=self._plural,
        name=self.ref.name,
        namespace=self.ref.namespace,
        body=body,
    )
    log.info("patching nmstate config %s: %s", self.ref, pformat(body))