Fixed var not found error