From 4b74448b21da90988fbf46810d864dfb92a5d7cc Mon Sep 17 00:00:00 2001 From: Oliver Hamlet Date: Thu, 27 Jun 2024 08:26:11 +0100 Subject: [PATCH] Update esplugin --- Cargo.lock | 2 +- src/plugin.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index c6c82b0..a723172 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -288,7 +288,7 @@ dependencies = [ [[package]] name = "esplugin" version = "5.0.1" -source = "git+https://github.com/Ortham/esplugin.git?branch=medium-masters#6afda81f124b5768e7534813ab776f790921de62" +source = "git+https://github.com/Ortham/esplugin.git?branch=medium-masters#b1910f5ab902ef8b34dfe344461ebf83d4f665cb" dependencies = [ "encoding_rs", "nom", diff --git a/src/plugin.rs b/src/plugin.rs index 1adcb04..6129381 100644 --- a/src/plugin.rs +++ b/src/plugin.rs @@ -84,7 +84,7 @@ impl Plugin { .map_err(|e| Error::IoError(path.to_path_buf(), e))?; let mut data = esplugin::Plugin::new(game_id.to_esplugin_id(), path); - data.parse_open_file(file, true) + data.parse_reader(file, esplugin::ParseOptions::header_only()) .map_err(|e| file_error(path, e))?; Ok(Plugin { @@ -156,7 +156,7 @@ impl Plugin { self.data = esplugin::Plugin::new(self.data.game_id(), &new_path); self.data - .parse_file(true) + .parse_file(esplugin::ParseOptions::header_only()) .map_err(|e| file_error(self.data.path(), e))?; let modification_time = self.modification_time(); self.set_modification_time(modification_time)?;