Console: Show "--" for values < 1 on profiles tabs

This commit is contained in:
zzz
2022-12-07 17:35:14 -05:00
parent 8ada237bfa
commit 59afc44c8a

View File

@@ -419,7 +419,15 @@ class ProfileOrganizerRenderer {
}
private final static DecimalFormat _fmt = new DecimalFormat("###,##0.00");
private final static String num(double num) { synchronized (_fmt) { return _fmt.format(num); } }
private final static String num(double num) {
if (num >= 1.0d) {
synchronized (_fmt) { return _fmt.format(num); }
} else {
return NA;
}
}
private final static String NA = "--";
private String avg (PeerProfile prof, long rate, RateAverages ra) {