fixing typo, was referencing an undefined variable