summaryrefslogtreecommitdiff
path: root/redfish-core/lib/sensors.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'redfish-core/lib/sensors.hpp')
-rw-r--r--redfish-core/lib/sensors.hpp21
1 files changed, 10 insertions, 11 deletions
diff --git a/redfish-core/lib/sensors.hpp b/redfish-core/lib/sensors.hpp
index 0772da559f..e04eac671f 100644
--- a/redfish-core/lib/sensors.hpp
+++ b/redfish-core/lib/sensors.hpp
@@ -756,8 +756,8 @@ inline void objectPropertiesToJson(
}
sensorJson["Status"]["State"] = getState(inventoryItem);
- sensorJson["Status"]["Health"] =
- getHealth(sensorJson, propertiesDict, inventoryItem);
+ sensorJson["Status"]["Health"] = getHealth(sensorJson, propertiesDict,
+ inventoryItem);
// Parameter to set to override the type we get from dbus, and force it to
// int, regardless of what is available. This is used for schemas like fan,
@@ -959,7 +959,6 @@ inline void objectInterfacesToJson(
const dbus::utility::DBusInteracesMap& interfacesDict,
nlohmann::json& sensorJson, InventoryItem* inventoryItem)
{
-
for (const auto& [interface, valuesDict] : interfacesDict)
{
objectPropertiesToJson(sensorName, sensorType, chassisSubNode,
@@ -1113,10 +1112,10 @@ inline void populateFanRedundancy(
}
}
- size_t minNumNeeded =
- collection->empty()
- ? 0
- : collection->size() - *allowedFailures;
+ size_t minNumNeeded = collection->empty()
+ ? 0
+ : collection->size() -
+ *allowedFailures;
nlohmann::json& jResp = sensorsAsyncResp->asyncResp->res
.jsonValue["Redundancy"];
@@ -1262,8 +1261,8 @@ inline void addInventoryItem(
const std::string& invItemObjPath, const std::string& sensorObjPath)
{
// Look for inventory item in vector
- InventoryItem* inventoryItem =
- findInventoryItem(inventoryItems, invItemObjPath);
+ InventoryItem* inventoryItem = findInventoryItem(inventoryItems,
+ invItemObjPath);
// If inventory item doesn't exist in vector, add it
if (inventoryItem == nullptr)
@@ -1456,8 +1455,8 @@ static void getInventoryItemsData(
static_cast<const std::string&>(objDictEntry.first);
// If this object path is one of the specified inventory items
- InventoryItem* inventoryItem =
- findInventoryItem(inventoryItems, objPath);
+ InventoryItem* inventoryItem = findInventoryItem(inventoryItems,
+ objPath);
if (inventoryItem != nullptr)
{
// Store inventory data in InventoryItem