aboutsummaryrefslogtreecommitdiffstats
path: root/askama_derive/src/config.rs
diff options
context:
space:
mode:
authorLibravatar René Kijewski <rene.kijewski@fu-berlin.de>2023-01-24 10:14:47 +0100
committerLibravatar Dirkjan Ochtman <dirkjan@ochtman.nl>2023-01-30 10:10:49 +0100
commit071106d94254d67388de64f0a7727732b345f413 (patch)
tree2e4915f49d4a0d2fe531227915285e6e6684bbfe /askama_derive/src/config.rs
parent58e02a4fb6f6d58ff68d18f24abcfc8cab53f7be (diff)
downloadaskama-071106d94254d67388de64f0a7727732b345f413.tar.gz
askama-071106d94254d67388de64f0a7727732b345f413.tar.bz2
askama-071106d94254d67388de64f0a7727732b345f413.zip
Use `toml_edit` instead of `toml`
Since version 0.6, `toml` is a wrapper around `toml_edit`, and the more basic library already meets our needs.
Diffstat (limited to 'askama_derive/src/config.rs')
-rw-r--r--askama_derive/src/config.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/askama_derive/src/config.rs b/askama_derive/src/config.rs
index 4dcf1ea..a075744 100644
--- a/askama_derive/src/config.rs
+++ b/askama_derive/src/config.rs
@@ -192,7 +192,8 @@ struct RawConfig {
impl RawConfig {
#[cfg(feature = "config")]
fn from_toml_str(s: &str) -> std::result::Result<RawConfig, CompileError> {
- toml::from_str(s).map_err(|e| format!("invalid TOML in {CONFIG_FILE_NAME}: {e}").into())
+ toml_edit::de::from_str(s)
+ .map_err(|e| format!("invalid TOML in {CONFIG_FILE_NAME}: {e}").into())
}
#[cfg(not(feature = "config"))]