Solved bug in updating minimum value.