Fixed using wrong variable name