From 12724c7e4dee1fbd6df1cf2ebf9f35a6afdc06ef Mon Sep 17 00:00:00 2001 From: Joshua Goins Date: Sun, 29 Jun 2025 20:33:33 -0400 Subject: [PATCH] Only generate plate HTML when connecting to Dalamud --- src/lib.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index ca373d1..efe250e 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -388,6 +388,9 @@ pub async fn archive_character(id: u64, use_dalamud: bool) -> Result, Ar zip.start_file("FFXIV_CHARA_01.dat", options)?; zip.write_all(&char_dat.write_to_buffer().unwrap())?; + zip.start_file("plate.html", options)?; + zip.write_all(create_plate_html(&char_data).as_ref())?; + // Stop the HTTP server let stop_url = Url::parse("http://localhost:42072/stop").map_err(|_| ArchiveError::UnknownError)?; @@ -401,9 +404,6 @@ pub async fn archive_character(id: u64, use_dalamud: bool) -> Result, Ar zip.start_file("character.html", options)?; zip.write_all(create_character_html(&char_data).as_ref())?; - zip.start_file("plate.html", options)?; - zip.write_all(create_plate_html(&char_data).as_ref())?; - zip.finish()?; Ok(buf)