Fixed issue with wrong variable being passed in