Added the right variables for functions