fix broken iterator