fixed a typo used wrong variable name