From 817e6f6ab6bc1c8cf46ed5076d09caee8c32c621 Mon Sep 17 00:00:00 2001 From: Martin Cornelis Date: Fri, 12 Jan 2024 15:34:22 +0100 Subject: [PATCH] Increase clarity of prefix_ by renaming it to analyzers_ns_ --- diagnostic_aggregator/src/add_analyzer.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/diagnostic_aggregator/src/add_analyzer.cpp b/diagnostic_aggregator/src/add_analyzer.cpp index 505af504..996ab443 100644 --- a/diagnostic_aggregator/src/add_analyzer.cpp +++ b/diagnostic_aggregator/src/add_analyzer.cpp @@ -66,7 +66,7 @@ class AddAnalyzer : public rclcpp::Node std::map parameters; if (this->get_parameters("", parameters)) { for (const auto & param : parameters) { - if (param.first.substr(0, prefix_.length()).compare(prefix_) == 0) { + if (param.first.substr(0, analyzers_ns_.length()).compare(analyzers_ns_) == 0) { auto parameter_msg = param.second.to_parameter_msg(); request->parameters.push_back(parameter_msg); } @@ -85,7 +85,7 @@ class AddAnalyzer : public rclcpp::Node private: rclcpp::Client::SharedPtr client_; - std::string prefix_ = "analyzers."; + std::string analyzers_ns_ = "analyzers."; }; int main(int argc, char ** argv)