main view users helper function, added docstring to helper function