Skip to content

Commit

Permalink
https://telecominfraproject.atlassian.net/browse/WIFI-13200
Browse files Browse the repository at this point in the history
Signed-off-by: stephb9959 <[email protected]>
  • Loading branch information
stephb9959 committed Dec 15, 2023
1 parent 51d7e59 commit 0121ed5
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions src/sdks/SDK_fms.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,18 +44,13 @@ namespace OpenWifi::SDK::FMS {
auto StatusCode = API.Do(CallResponse);
if (StatusCode == Poco::Net::HTTPResponse::HTTP_OK) {
Poco::JSON::Array::Ptr FirmwareArr = CallResponse->getArray("firmwares");
for (uint64_t i = 0; i < FirmwareArr->size(); i++) {
for(const auto &firmware:*FirmwareArr) {
auto Object = firmware.extract<Poco::JSON::Object::Ptr>();
FMSObjects::Firmware F;
F.from_json(FirmwareArr->getObject(i));
F.from_json(Object);
std::cout << "Adding firmware: " << F.revision << std::endl;
FirmWares.emplace_back(F);
}
int done=0;
if(!done) {
for (const auto &Firmware: FirmWares) {
std::cout << "Firmware: " << Firmware.revision << std::endl;
}
done=1;
}
return true;
}
return false;
Expand Down

0 comments on commit 0121ed5

Please sign in to comment.