Fix NameError

Fixed a typo that results in a NameError