Cleaned up XMLReader