summaryrefslogtreecommitdiff
path: root/redfish-core/lib/update_service.hpp
diff options
context:
space:
mode:
authorEd Tanous <ed.tanous@intel.com>2018-11-30 22:35:41 +0300
committerEd Tanous <ed.tanous@intel.com>2018-12-10 23:54:40 +0300
commit1b6b96c570fdf7ca5c643f3d0776581656e78070 (patch)
treed96338cf9f95ea763e4fb6570d83e4d1808d3f41 /redfish-core/lib/update_service.hpp
parent789a6a317b51abba38cf064dd5ee2abd051d02bf (diff)
downloadbmcweb-1b6b96c570fdf7ca5c643f3d0776581656e78070.tar.xz
Remove custom version of getPtr
Now that sdbusplus variant supports std::get_if, we can remove our custom, mapbox namespaced implementation that does the same thing. Change-Id: I854c473003e28e41dd45dba08ca683433f1c1774 Signed-off-by: Ed Tanous <ed.tanous@intel.com>
Diffstat (limited to 'redfish-core/lib/update_service.hpp')
-rw-r--r--redfish-core/lib/update_service.hpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/redfish-core/lib/update_service.hpp b/redfish-core/lib/update_service.hpp
index f600c14e2f..d5ecf24765 100644
--- a/redfish-core/lib/update_service.hpp
+++ b/redfish-core/lib/update_service.hpp
@@ -260,8 +260,8 @@ class SoftwareInventoryCollection : public Node
}
const std::string *swActivationStatus =
- mapbox::getPtr<const std::string>(
- activation);
+ sdbusplus::message::variant_ns::get_if<
+ std::string>(&activation);
if (swActivationStatus == nullptr)
{
messages::internalError(asyncResp->res);
@@ -401,7 +401,8 @@ class SoftwareInventory : public Node
return;
}
const std::string *swInvPurpose =
- mapbox::getPtr<const std::string>(it->second);
+ sdbusplus::message::variant_ns::get_if<
+ std::string>(&it->second);
if (swInvPurpose == nullptr)
{
BMCWEB_LOG_DEBUG
@@ -426,7 +427,8 @@ class SoftwareInventory : public Node
BMCWEB_LOG_DEBUG << "Version found!";
const std::string *version =
- mapbox::getPtr<const std::string>(it->second);
+ sdbusplus::message::variant_ns::get_if<
+ std::string>(&it->second);
if (version == nullptr)
{