fix for maximum values not being read