groups changed to be obj orrientated. Directroy assigning written but not tested