From 4497d9d095dff6141d899720106581b2696f5ba1 Mon Sep 17 00:00:00 2001 From: Andrew Phillips Date: Tue, 26 Aug 2025 16:21:20 -0300 Subject: [PATCH] refactor: rename PluginResponse to MetaPluginResponse Co-authored-by: aider (openai/andrew/openrouter/mistralai/mistral-medium-3.1) --- src/meta_plugin/program.rs | 8 ++++---- src/meta_plugin/system.rs | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/meta_plugin/program.rs b/src/meta_plugin/program.rs index 65e5c9c..0d1c16a 100644 --- a/src/meta_plugin/program.rs +++ b/src/meta_plugin/program.rs @@ -122,10 +122,10 @@ impl MetaPlugin for MetaPluginProgram { self.writer = Some(Box::new(stdin)); self.process = Some(process); - Ok(PluginResponse::default()) + Ok(MetaPluginResponse::default()) } - fn finalize(&mut self) -> Result { + fn finalize(&mut self) -> Result { debug!("META: Finalizing program plugin"); let mut metadata = Vec::new(); @@ -165,13 +165,13 @@ impl MetaPlugin for MetaPluginProgram { } } - Ok(PluginResponse { + Ok(MetaPluginResponse { metadata: if metadata.is_empty() { None } else { Some(metadata) }, is_finalized: true, }) } - fn update(&mut self, data: &[u8]) -> Result { + fn update(&mut self, data: &[u8]) -> Result { if let Some(ref mut writer) = self.writer { if let Err(e) = writer.write_all(data) { debug!("META: Failed to write to process stdin: {}", e); diff --git a/src/meta_plugin/system.rs b/src/meta_plugin/system.rs index e7ab5c3..1ac5b29 100644 --- a/src/meta_plugin/system.rs +++ b/src/meta_plugin/system.rs @@ -60,9 +60,9 @@ impl MetaPlugin for CwdMetaPlugin { true } - fn finalize(&mut self) -> Result { + fn finalize(&mut self) -> Result { // Since we save during initialize(), return Ok to avoid duplicate saves - Ok(PluginResponse::default()) + Ok(MetaPluginResponse::default()) } fn update(&mut self, _data: &[u8]) -> Result { @@ -74,7 +74,7 @@ impl MetaPlugin for CwdMetaPlugin { self.meta_name.clone() } - fn initialize(&mut self, conn: &Connection, item_id: i64) -> Result<()> { + fn initialize(&mut self, conn: &Connection, item_id: i64) -> Result { let cwd = match env::current_dir() { Ok(path) => path.to_string_lossy().to_string(), Err(_) => "unknown".to_string(), @@ -182,7 +182,7 @@ impl MetaPlugin for UidMetaPlugin { metadata.push(meta); } - Ok(PluginResponse { + Ok(MetaPluginResponse { metadata: Some(metadata), is_finalized: true, })