Removes unused variables from Controller