avoid empty hosts list error