From 3db30f24c76361b13be215a0f6b0738a4cefc466 Mon Sep 17 00:00:00 2001 From: Kory Draughn Date: Mon, 4 Mar 2024 11:37:48 -0500 Subject: [PATCH] [?] Small code refactor - use fmtlib. --- indexing_utilities.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/indexing_utilities.cpp b/indexing_utilities.cpp index ea58b07..419ee62 100644 --- a/indexing_utilities.cpp +++ b/indexing_utilities.cpp @@ -513,7 +513,7 @@ namespace irods::indexing std::string indexer::generate_delay_execution_parameters() { - std::string params{config_.delay_parameters + "" + config_.instance_name + ""}; + auto params = fmt::format("{}{}", config_.delay_parameters, config_.instance_name); int min_time = config_.minimum_delay_time <= 0 ? 1 : config_.minimum_delay_time; int max_time = config_.maximum_delay_time <= 0 ? 30 : config_.maximum_delay_time; @@ -528,12 +528,11 @@ namespace irods::indexing catch (const boost::bad_lexical_cast&) { } - params += "" + sleep_time + "s"; + params += fmt::format("{}s", sleep_time); rodsLog(config_.log_level, "indexing: delay params min=[%d], max=[%d], computed=[%s]", min_time, max_time, params.c_str()); return params; - } // generate_delay_execution_parameters void indexer::get_metadata_for_data_object(const std::string& _meta_attr_name,