fixed use of vars