fix bad variable name and update spec tests