fixed xml cleanup