Skip to content

Commit

Permalink
Fix diff calculations
Browse files Browse the repository at this point in the history
  • Loading branch information
muhamadazmy committed May 5, 2022
1 parent 11516d7 commit d65307a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/rrd/rrd.go
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ func (r *rrdSlot) Counter(key string, value float64) error {
return nil
}
diff := 0.0
if value > last {
if value >= last {
diff = value - last
} else {
// this is either an overflow
Expand Down

0 comments on commit d65307a

Please sign in to comment.