Skip to content

Commit 692dccd

Browse files
committed
Fix needsFlushing() logic inversion in SimpleErrorTracker
1 parent a807b92 commit 692dccd

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

core/src/main/java/dev/faststats/core/SimpleErrorTracker.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,11 @@ public void clear() {
7171
}
7272

7373
public boolean needsFlushing() {
74-
if (!reports.isEmpty()) return false;
74+
if (!reports.isEmpty()) return true;
7575
for (final var value : collected.values()) {
76-
if (value > 0) return false;
76+
if (value > 0) return true;
7777
}
78-
return true;
79-
78+
return false;
8079
}
8180

8281
@Override

0 commit comments

Comments
 (0)