Commit 7afc134b6befa427371c62f1e8b16a9178df1a7b
1 parent
d893697d
Exists in
master
Correção coleta
Showing
1 changed file
with
4 additions
and
1 deletions
Show diff stats
src/cacic_hardware.cpp
| ... | ... | @@ -51,7 +51,10 @@ QJsonObject cacic_hardware::coletaWin() |
| 51 | 51 | // (Verifica se é notebook) |
| 52 | 52 | params.clear(); |
| 53 | 53 | wmiResult = wmi::wmiSearch("Win32_PortableBattery", params); |
| 54 | - hardware["IsNotebook"] = QJsonValue::fromVariant(!wmiResult.isNull()); | |
| 54 | + QJsonObject notebook; | |
| 55 | + notebook["Value"] = QJsonValue::fromVariant(!wmiResult.isNull()); | |
| 56 | + hardware["IsNotebook"] = notebook; | |
| 57 | + delete notebook; | |
| 55 | 58 | if (!wmiResult.isNull()){ |
| 56 | 59 | hardware["PortableBattery"] = wmiResult; |
| 57 | 60 | } | ... | ... |