From 064791e56598a2b4a7c1d4d947dd55ad63b9881d Mon Sep 17 00:00:00 2001 From: Wolfgang Bumiller Date: Wed, 29 Jun 2022 10:11:28 +0200 Subject: [PATCH] section-config: clippy fixes Signed-off-by: Wolfgang Bumiller --- proxmox-section-config/src/lib.rs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/proxmox-section-config/src/lib.rs b/proxmox-section-config/src/lib.rs index 85ff81b8..154f56e0 100644 --- a/proxmox-section-config/src/lib.rs +++ b/proxmox-section-config/src/lib.rs @@ -899,11 +899,14 @@ pub fn dump_section_config(config: &SectionConfig) -> String { }; if plugin_count > 1 { + use std::fmt::Write as _; + let description = wrap_text("", "", properties.description(), 80); - res.push_str(&format!( + let _ = write!( + res, "\n**Section type** \'``{}``\': {}\n\n", name, description - )); + ); } res.push_str(&dump_properties(