added better naming of function