fixed incorrect local variable name