changed variable names and removed unnecesary vars
merges with master