Fixed - missing var, poluting global variables