chore(plugins): replace deprecated zip-extract with zip

This commit is contained in:
Gregory Schier
2026-09-15 14:24:13 -07:00
parent 0b6803c6c0
commit 85904566e7
4 changed files with 5 additions and 50 deletions
+1 -1
View File
@@ -27,4 +27,4 @@ yaak-common = { workspace = true }
yaak-crypto = { workspace = true }
yaak-models = { workspace = true }
yaak-templates = { workspace = true }
zip-extract = "0.4.0"
zip = "7"
+1 -1
View File
@@ -43,7 +43,7 @@ pub enum Error {
PluginErr(String),
#[error("zip error: {0}")]
ZipError(#[from] zip_extract::ZipExtractError),
ZipError(#[from] zip::result::ZipError),
#[error("Client not initialized error")]
ClientNotInitializedErr,
+2 -1
View File
@@ -65,7 +65,8 @@ pub async fn download_and_install(
let _ = remove_dir_all(&plugin_dir);
create_dir_all(&plugin_dir)?;
zip_extract::extract(Cursor::new(&bytes), &plugin_dir, true)?;
zip::ZipArchive::new(Cursor::new(&bytes))?
.extract_unwrapped_root_dir(&plugin_dir, zip::read::root_dir_common_filter)?;
info!("Extracted plugin {} to {}", plugin_version.id, plugin_dir_str);
let plugin = query_manager.with_tx(|db| {