make sure that the number of entries are greater than zero when updating