From 1127b010478e7b4deb523fed544b900fa724ef3e Mon Sep 17 00:00:00 2001 From: 魏曹先生 <1992414357@qq.com> Date: Sat, 10 Jan 2026 06:12:50 +0800 Subject: Fix typo in field names from "modifiy" to "modify" --- crates/vcs_data/src/data/local/local_sheet.rs | 30 +++++++++++----------- .../vcs_data/src/data/local/workspace_analyzer.rs | 12 ++++----- 2 files changed, 21 insertions(+), 21 deletions(-) (limited to 'crates/vcs_data') diff --git a/crates/vcs_data/src/data/local/local_sheet.rs b/crates/vcs_data/src/data/local/local_sheet.rs index 8ad059f..6f9924c 100644 --- a/crates/vcs_data/src/data/local/local_sheet.rs +++ b/crates/vcs_data/src/data/local/local_sheet.rs @@ -67,15 +67,15 @@ pub struct LocalMappingMetadata { /// Latest modifiy check time #[serde(rename = "check_time")] - pub(crate) last_modifiy_check_time: SystemTime, + pub(crate) last_modify_check_time: SystemTime, /// Latest modifiy check result #[serde(rename = "modified")] - pub(crate) last_modifiy_check_result: bool, + pub(crate) last_modify_check_result: bool, /// Latest modifiy check hash result #[serde(rename = "current_hash")] - pub(crate) last_modifiy_check_hash: Option, + pub(crate) last_modify_check_hash: Option, } impl LocalSheetData { @@ -115,9 +115,9 @@ impl LocalMappingMetadata { version_desc_when_updated, version_when_updated, mapping_vfid, - last_modifiy_check_time, - last_modifiy_check_result, - last_modifiy_check_hash: None, + last_modify_check_time: last_modifiy_check_time, + last_modify_check_result: last_modifiy_check_result, + last_modify_check_hash: None, } } @@ -183,32 +183,32 @@ impl LocalMappingMetadata { /// Getter for last_modifiy_check_time pub fn last_modifiy_check_time(&self) -> &SystemTime { - &self.last_modifiy_check_time + &self.last_modify_check_time } /// Setter for last_modifiy_check_time pub fn set_last_modifiy_check_time(&mut self, time: SystemTime) { - self.last_modifiy_check_time = time; + self.last_modify_check_time = time; } /// Getter for last_modifiy_check_result pub fn last_modifiy_check_result(&self) -> bool { - self.last_modifiy_check_result + self.last_modify_check_result } /// Setter for last_modifiy_check_result pub fn set_last_modifiy_check_result(&mut self, result: bool) { - self.last_modifiy_check_result = result; + self.last_modify_check_result = result; } /// Getter for last_modifiy_check_hash pub fn last_modifiy_check_hash(&self) -> &Option { - &self.last_modifiy_check_hash + &self.last_modify_check_hash } /// Setter for last_modifiy_check_hash pub fn set_last_modifiy_check_hash(&mut self, hash: Option) { - self.last_modifiy_check_hash = hash; + self.last_modify_check_hash = hash; } } @@ -221,9 +221,9 @@ impl Default for LocalMappingMetadata { version_desc_when_updated: Default::default(), version_when_updated: Default::default(), mapping_vfid: Default::default(), - last_modifiy_check_time: SystemTime::now(), - last_modifiy_check_result: false, - last_modifiy_check_hash: None, + last_modify_check_time: SystemTime::now(), + last_modify_check_result: false, + last_modify_check_hash: None, } } } diff --git a/crates/vcs_data/src/data/local/workspace_analyzer.rs b/crates/vcs_data/src/data/local/workspace_analyzer.rs index a17063c..f2d83ff 100644 --- a/crates/vcs_data/src/data/local/workspace_analyzer.rs +++ b/crates/vcs_data/src/data/local/workspace_analyzer.rs @@ -200,7 +200,7 @@ impl<'a> AnalyzeResult<'a> { // Using the most recently recorded Hash can more accurately identify moved items, // but if it doesn't exist, fall back to the initially recorded Hash mapping_data - .last_modifiy_check_hash + .last_modify_check_hash .as_ref() .cloned() .unwrap_or(mapping_data.hash_when_updated.clone()), @@ -295,16 +295,16 @@ impl<'a> AnalyzeResult<'a> { result.modified.insert(path.clone()); // Update last modified check time to modified time - mapping_data.last_modifiy_check_time = modified_time; - mapping_data.last_modifiy_check_result = true; + mapping_data.last_modify_check_time = modified_time; + mapping_data.last_modify_check_result = true; } else { // Update last modified check time to modified time - mapping_data.last_modifiy_check_time = modified_time; - mapping_data.last_modifiy_check_result = false; + mapping_data.last_modify_check_time = modified_time; + mapping_data.last_modify_check_result = false; } // Record latest hash - mapping_data.last_modifiy_check_hash = Some(hash_calc.hash) + mapping_data.last_modify_check_hash = Some(hash_calc.hash) } // Persist the local sheet data -- cgit