Undefined variable bugfix.