[fronius] [fronius] Accept null value as zero for inverterdatachannelpac channel (#9077)
Signed-off-by: Jimmy Tanagra <jcode@tanagra.id.au>
This commit is contained in:
parent
bc0fafd10b
commit
ae7d5715ee
|
@ -93,7 +93,12 @@ public class FroniusSymoInverterHandler extends FroniusBaseThingHandler {
|
|||
}
|
||||
return day;
|
||||
case FroniusBindingConstants.InverterDataChannelPac:
|
||||
return inverterRealtimeResponse.getBody().getData().getPac();
|
||||
ValueUnit pac = inverterRealtimeResponse.getBody().getData().getPac();
|
||||
if (pac == null) {
|
||||
pac = new ValueUnit();
|
||||
pac.setValue(0);
|
||||
}
|
||||
return pac;
|
||||
case FroniusBindingConstants.InverterDataChannelTotal:
|
||||
ValueUnit total = inverterRealtimeResponse.getBody().getData().getTotalEnergy();
|
||||
if (total != null) {
|
||||
|
|
Loading…
Reference in New Issue