removed unneeded parameters from function