Added more if statements to handle different cases better, created a CapturedServices.xml in the project/XML folder