bugfix, undefined  variable