removed a few unused function arguments