got rid of deprecated code for xml usage