removed use of undefined variable