Added checks and override for .xml endings

I made the necessary changes to the rest of the files to account for this minor change.  Please have a look, thanks!