Consitently use dbus::utility types
This saves about 4k on the binary size
Tested: Redfish service validator passes.
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: I9546227a19c691b1aecb80e80307889548c0293f
diff --git a/redfish-core/lib/storage.hpp b/redfish-core/lib/storage.hpp
index a2a2201..6809958 100644
--- a/redfish-core/lib/storage.hpp
+++ b/redfish-core/lib/storage.hpp
@@ -64,7 +64,8 @@
crow::connections::systemBus->async_method_call(
[asyncResp,
health](const boost::system::error_code ec,
- const std::vector<std::string>& storageList) {
+ const dbus::utility::MapperGetSubTreePathsResponse&
+ storageList) {
nlohmann::json& storageArray =
asyncResp->res.jsonValue["Drives"];
storageArray = nlohmann::json::array();
@@ -110,9 +111,9 @@
"xyz.openbmc_project.Inventory.Item.Drive"});
crow::connections::systemBus->async_method_call(
- [asyncResp,
- health](const boost::system::error_code ec,
- const crow::openbmc_mapper::GetSubTreeType& subtree) {
+ [asyncResp, health](
+ const boost::system::error_code ec,
+ const dbus::utility::MapperGetSubTreeResponse& subtree) {
if (ec || subtree.empty())
{
// doesn't have to be there
@@ -481,9 +482,9 @@
bmcweb::AsyncResp>& asyncResp,
const std::string& driveId) {
crow::connections::systemBus->async_method_call(
- [asyncResp,
- driveId](const boost::system::error_code ec,
- const crow::openbmc_mapper::GetSubTreeType& subtree) {
+ [asyncResp, driveId](
+ const boost::system::error_code ec,
+ const dbus::utility::MapperGetSubTreeResponse& subtree) {
if (ec)
{
BMCWEB_LOG_ERROR << "Drive mapper call error";