refactored assign users