renamed locationsFactory to locationFactory to match file name.