getBaseUnit method

BaseUnit? getBaseUnit(
  1. String code
)

Implementation

BaseUnit? getBaseUnit(String code) {
  for (final BaseUnit unit in baseUnits) {
    if (unit.code == code) {
      return unit;
    }
  }
  return null;
}