diff --git a/core/loadpoint_session.go b/core/loadpoint_session.go index 15fc90dad..c58bec59d 100644 --- a/core/loadpoint_session.go +++ b/core/loadpoint_session.go @@ -58,8 +58,7 @@ func (lp *Loadpoint) stopSession() { } s.Finished = lp.clock.Now() - meterStop := lp.chargeMeterTotal() - if meterStop > 0 { + if meterStop := lp.chargeMeterTotal(); meterStop > 0 { s.MeterStop = &meterStop }