added check for population 0 or null