stopping prev going below 0