Fix scope issues.