fix: gate parse_gemini_keychain_json with cfg(target_os = "macos")

The function is only called from read_gemini_credentials_from_keychain
which is already macOS-only. Without the gate, non-macOS CI fails with
dead-code error due to -D warnings.
This commit is contained in:
Jason
2026-04-05 16:04:20 +08:00
parent 4685e5b597
commit 602c5717b2
+1
View File
@@ -778,6 +778,7 @@ fn read_gemini_credentials_from_keychain() -> Option<GeminiCredentials> {
/// ```json
/// { "token": { "accessToken": "...", "refreshToken": "...", "expiresAt": 1234 }, "updatedAt": ... }
/// ```
#[cfg(target_os = "macos")]
fn parse_gemini_keychain_json(content: &str) -> GeminiCredentials {
let parsed: serde_json::Value = match serde_json::from_str(content) {
Ok(v) => v,