Use right name and type for variable

Wrongly named variable, and type was missing too.