moved variables so they are all in one location