based on admin and users func