Fix min/max (again!)