Removed endless loop in zookeeper