changed the structure for better access