fix xml heading condition