Variable scoping issue.