diff --git a/crates/collab/src/db/tables/user.rs b/crates/collab/src/db/tables/user.rs index 8e8c03fafc..3f753954eb 100644 --- a/crates/collab/src/db/tables/user.rs +++ b/crates/collab/src/db/tables/user.rs @@ -39,25 +39,6 @@ pub enum Relation { Contributor, } -impl Model { - /// Returns the timestamp of when the user's account was created. - /// - /// This will be the earlier of the `created_at` and `github_user_created_at` timestamps. - pub fn account_created_at(&self) -> NaiveDateTime { - let mut account_created_at = self.created_at; - if let Some(github_created_at) = self.github_user_created_at { - account_created_at = account_created_at.min(github_created_at); - } - - account_created_at - } - - /// Returns the age of the user's account. - pub fn account_age(&self) -> chrono::Duration { - chrono::Utc::now().naive_utc() - self.account_created_at() - } -} - impl Related for Entity { fn to() -> RelationDef { Relation::AccessToken.def()