Changed function parameter names to be more readable