Revert "NB5 address high priority code scans" (#895)

This commit is contained in:
Jeff Banks
2023-01-05 13:06:49 -06:00
committed by Mike Yaacoub
parent ecfe3d633f
commit 2d16ff3b57
2 changed files with 15 additions and 15 deletions

View File

@@ -130,7 +130,7 @@ public class Unit {
Matcher m = numberFmtPattern.matcher(spec);
if (m.matches()) {
String numberpart = m.group("number");
double base = Double.parseDouble(numberpart);
long base = Long.valueOf(numberpart);
String unitpart = m.group("unit");
if (unitpart != null) {
Count specifierUnit = Count.valueOfSuffix(unitpart);
@@ -142,7 +142,7 @@ public class Unit {
double multiplier = (specifierScale / resultScale);
base *= multiplier;
}
return Optional.of((long) base);
return Optional.of(base);
} else {
logger.error("Parsing error for specifier:'" + spec + "'");
return Optional.empty();