Fix tracking of the last value.