create userlist function