added nil check to the location and track extractor