File size: 1,255 Bytes
d567e54
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
{
  "commit_sha": "fdff489f0ba481db7ea8cf9990b2ff607d0624aa",
  "pr_number": 10070,
  "rust_files": [
    "crates/router/src/core/unified_connector_service.rs"
  ],
  "diffs": [
    {
      "id": "crates/router/src/core/unified_connector_service.rs::function::get_rollout_percentage",
      "file": "crates/router/src/core/unified_connector_service.rs",
      "kind": "function_item",
      "status": "removed",
      "before_code": "async fn get_rollout_percentage(state: &SessionState, config_key: &str) -> Option<f64> {\n    let db = state.store.as_ref();\n\n    match db.find_config_by_key(config_key).await {\n        Ok(rollout_config) => {\n            // Try to parse as JSON first (new format), fallback to float (legacy format)\n            match serde_json::from_str::<helpers::RolloutConfig>(&rollout_config.config) {\n                Ok(config) => Some(config.rollout_percent),\n                Err(_) => {\n                    // Fallback to legacy format (simple float)\n                    rollout_config.config.parse::<f64>().ok()\n                }\n            }\n        }\n        Err(_) => None,\n    }\n}",
      "after_code": null,
      "diff_span": null,
      "commit_sha": "fdff489f0ba481db7ea8cf9990b2ff607d0624aa"
    }
  ]
}