(
base: &mut serde_json::Map<String, serde_json::Value>,
other: serde_json::Map<String, serde_json::Value>,
)
| 288 | } |
| 289 | |
| 290 | fn merge_maps_disjoint( |
| 291 | base: &mut serde_json::Map<String, serde_json::Value>, |
| 292 | other: serde_json::Map<String, serde_json::Value>, |
| 293 | ) -> Result<(), AppError> { |
| 294 | for (key, value) in other { |
| 295 | if base.contains_key(&key) { |
| 296 | return Err(AppError::NotAcceptable(RpcError { |
| 297 | code: None, |
| 298 | message: format!("Duplicate key: {key}"), |
| 299 | data: None, |
| 300 | })); |
| 301 | } |
| 302 | base.insert(key, value); |
| 303 | } |
| 304 | Ok(()) |
| 305 | } |
| 306 | |
| 307 | fn convert_json_to_response( |
| 308 | headers: axum::http::HeaderMap, |
no test coverage detected