From 2552de485836ae6d8c90a56deac7b93a3f4cadcf Mon Sep 17 00:00:00 2001 From: Anthony Shew Date: Wed, 1 Oct 2025 06:19:20 -0700 Subject: [PATCH 1/2] chore: remove unused origin field from struct --- crates/turborepo-auth/src/auth/login.rs | 1 - crates/turborepo-auth/src/auth/sso.rs | 1 - crates/turborepo-auth/src/lib.rs | 7 ------- crates/turborepo-vercel-api/src/token.rs | 1 - 4 files changed, 10 deletions(-) diff --git a/crates/turborepo-auth/src/auth/login.rs b/crates/turborepo-auth/src/auth/login.rs index e63c199b93201..11eb06cd349ed 100644 --- a/crates/turborepo-auth/src/auth/login.rs +++ b/crates/turborepo-auth/src/auth/login.rs @@ -282,7 +282,6 @@ mod tests { id: "id".to_string(), name: "name".to_string(), token_type: "token".to_string(), - origin: "github".to_string(), scopes: vec![turborepo_vercel_api::token::Scope { scope_type: "user".to_string(), origin: "github".to_string(), diff --git a/crates/turborepo-auth/src/auth/sso.rs b/crates/turborepo-auth/src/auth/sso.rs index 5b10000117cdc..bec9af49b4ae4 100644 --- a/crates/turborepo-auth/src/auth/sso.rs +++ b/crates/turborepo-auth/src/auth/sso.rs @@ -274,7 +274,6 @@ mod tests { id: "test".to_string(), name: "test".to_string(), token_type: "test".to_string(), - origin: "test".to_string(), scopes: vec![Scope { scope_type: "team".to_string(), origin: "saml".to_string(), diff --git a/crates/turborepo-auth/src/lib.rs b/crates/turborepo-auth/src/lib.rs index 8881ad4f7d571..b126ddd62a832 100644 --- a/crates/turborepo-auth/src/lib.rs +++ b/crates/turborepo-auth/src/lib.rs @@ -406,7 +406,6 @@ mod tests { id: "".to_string(), name: "".to_string(), token_type: "".to_string(), - origin: "".to_string(), created_at: 0, }; @@ -678,7 +677,6 @@ mod tests { id: "test".to_string(), name: "test".to_string(), token_type: "test".to_string(), - origin: "test".to_string(), scopes: vec![], active_at: current_unix_time() - 100, created_at: 0, @@ -728,7 +726,6 @@ mod tests { id: "test".to_string(), name: "test".to_string(), token_type: "test".to_string(), - origin: "test".to_string(), scopes: vec![], active_at: current_time - 100, created_at: 0, @@ -745,7 +742,6 @@ mod tests { id: "test".to_string(), name: "test".to_string(), token_type: "test".to_string(), - origin: "test".to_string(), scopes: vec![], created_at: 0, active_at: 0, @@ -806,7 +802,6 @@ mod tests { id: "test".to_string(), name: "test".to_string(), token_type: "".to_string(), - origin: "test".to_string(), scopes: vec![], active_at: current_unix_time() - 100, created_at: 0, @@ -827,7 +822,6 @@ mod tests { id: "test".to_string(), name: "test".to_string(), token_type: "sso".to_string(), - origin: "test".to_string(), scopes: vec![], active_at: current_unix_time() - 100, created_at: 0, @@ -860,7 +854,6 @@ mod tests { id: "test".to_string(), name: "test".to_string(), token_type: "".to_string(), - origin: "test".to_string(), scopes: vec![], active_at: current_unix_time() - 100, created_at: 0, diff --git a/crates/turborepo-vercel-api/src/token.rs b/crates/turborepo-vercel-api/src/token.rs index f9872eb2b2e23..161fcbaac4c01 100644 --- a/crates/turborepo-vercel-api/src/token.rs +++ b/crates/turborepo-vercel-api/src/token.rs @@ -6,7 +6,6 @@ pub struct ResponseTokenMetadata { pub name: String, #[serde(rename = "type")] pub token_type: String, - pub origin: String, pub scopes: Vec, #[serde(rename = "activeAt")] pub active_at: u128, From df2a952415229e21c312c56caa8041845705866f Mon Sep 17 00:00:00 2001 From: Anthony Shew Date: Wed, 1 Oct 2025 06:27:54 -0700 Subject: [PATCH 2/2] remove from scope too --- crates/turborepo-auth/src/auth/login.rs | 1 - crates/turborepo-auth/src/auth/sso.rs | 1 - crates/turborepo-auth/src/lib.rs | 1 - crates/turborepo-vercel-api/src/token.rs | 1 - 4 files changed, 4 deletions(-) diff --git a/crates/turborepo-auth/src/auth/login.rs b/crates/turborepo-auth/src/auth/login.rs index 11eb06cd349ed..d223e96f0d43a 100644 --- a/crates/turborepo-auth/src/auth/login.rs +++ b/crates/turborepo-auth/src/auth/login.rs @@ -284,7 +284,6 @@ mod tests { token_type: "token".to_string(), scopes: vec![turborepo_vercel_api::token::Scope { scope_type: "user".to_string(), - origin: "github".to_string(), team_id: None, expires_at: None, created_at: 1111111111111, diff --git a/crates/turborepo-auth/src/auth/sso.rs b/crates/turborepo-auth/src/auth/sso.rs index bec9af49b4ae4..01d51d3865e72 100644 --- a/crates/turborepo-auth/src/auth/sso.rs +++ b/crates/turborepo-auth/src/auth/sso.rs @@ -276,7 +276,6 @@ mod tests { token_type: "test".to_string(), scopes: vec![Scope { scope_type: "team".to_string(), - origin: "saml".to_string(), team_id: Some("my-team".to_string()), created_at: 0, expires_at: None, diff --git a/crates/turborepo-auth/src/lib.rs b/crates/turborepo-auth/src/lib.rs index b126ddd62a832..09befb45c65c7 100644 --- a/crates/turborepo-auth/src/lib.rs +++ b/crates/turborepo-auth/src/lib.rs @@ -395,7 +395,6 @@ mod tests { let quick_scope = |expiry| Scope { expires_at: expiry, scope_type: "".to_string(), - origin: "".to_string(), created_at: 0, team_id: None, }; diff --git a/crates/turborepo-vercel-api/src/token.rs b/crates/turborepo-vercel-api/src/token.rs index 161fcbaac4c01..afd435a85e62d 100644 --- a/crates/turborepo-vercel-api/src/token.rs +++ b/crates/turborepo-vercel-api/src/token.rs @@ -17,7 +17,6 @@ pub struct ResponseTokenMetadata { pub struct Scope { #[serde(rename = "type")] pub scope_type: String, - pub origin: String, #[serde(rename = "createdAt")] pub created_at: u128, #[serde(rename = "expiresAt")]